0
votes
1answer
35 views

Command Line: Browse to a network path that has spaces and a single quote

I am trying to browse to a network path in dos that has both spaces and a single quote. When I do: net use "\\server\path's name\folder\" I get an error message that error 53 has occurred. Any ...
0
votes
1answer
29 views

What is the sequence of files bash loads to set PATH variable

I want to understand the way PATH variable is set in Linux/Mac. What all files are loaded and in what sequence to set the PATH variable for BASH.
0
votes
1answer
36 views

Java command only working in command line not in sh files

I have recently attempted to install java on ubuntu server 12.04 LTS. I wgetted the tar.gz file and extracted it to /opt/java and then added /opt/java/bin to the path variable. This all works ...
0
votes
1answer
69 views

SQLPLUS 32-bit Linux Pathing Issue

I am running linux 32 bit and installed Oracle 11g in it. I am trying to start sqlplus from command line but get the command not found error. I checked the environment variables and have ...
0
votes
1answer
664 views

$PATH - No such file or directory MAC OSX - Terminal

A million different version of this have been asked already, but I'm still lost, sorry. Here is some of what I'm getting back... In a terminal: $PATH -bash: ...
0
votes
0answers
26 views

Vagrantfile - is rvm in ~/.rvm/scripts/rvm or ~/.rvm/bin/rvm?

I'm still learning my way around some of the more hidden files in terminal and I was trying to setup a Vagrant box with rails via shell script provisioning, with some help from these links: ...
1
vote
1answer
69 views

Need help $PATH and terminal commands relink - no sudo, ps, grep

I had to change some path settings to install node.js in turn I must have edited a file that removed the path from the correct directory, whereby sudo, ps, grep etc. live. I am not sure how to reset ...
1
vote
3answers
2k views

How to add a line to .bash_profile

I just installed Homebrew on bash on my Mac and now I need to do this: Once you’ve installed Homebrew, insert the Homebrew directory at the top of your PATH environment variable. You can do ...
0
votes
2answers
190 views

How to change the $PATH in Mac OSX

I've installed git via the instaler and not with terminal with commands, and my $PATH changed, the path to the 'local' git was added the the end of the variable, and my $PATH changed to this: ...
0
votes
4answers
101 views

How to list folders in bash without the trailing /

I know ls -d */ lists all folder in current directory as dir1/ dir2/ dir3/. Is there the possibility in a bash script to show folders as dir1 dir2 dir3?
1
vote
4answers
134 views

Mac OS X keeps “old” environment variable around

So far I had /Applications/play-1.2.5/ added to my $PATH variable. Now I'm working with 2.2.1, which I installed in /Applications/play-2.2.1 and changed in ~/.bash_profile (which is getting sourced at ...
3
votes
2answers
584 views

How does Mac OS X set the value of $PATH?

I have a basic understanding on how the $PATH can be set, but is there a documentation that fully describes where Mac OS gets all the paths that get appended to $PATH? I'm aware of things like ...
0
votes
4answers
175 views

$PATH is not updated

It seems all about this was already discussed, but I can't resolve my problem. I have all necessary strings in /etc/paths /usr/bin /bin /usr/sbin /sbin /usr/local/bin in ~/.bash_profile export ...
1
vote
1answer
356 views

Why do my $PATH and /etc/paths Differ?

Typing export $PATH in Mountain Lion's Terminal returns ...
2
votes
3answers
97 views

How do I prevent $PATH from resetting itself each time?

I'm having difficulty setting up the PATH on my macbook pro. I followed this link to modify my path variable. Each time I start a new terminal I get a PATH pointing towards ...
1
vote
1answer
1k views

Where to store bash scripts that all users may execute on Debian?

I have many bash scripts on my server, that all users may use. but it seems the location /usr/local/sbin is not the best place. I don't want to use the home directory of the users, cause ...
0
votes
2answers
2k views

Add /usr/local/sbin to the PATH of a user [duplicate]

if I type echo $PATH I only get /usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games how can I add /usr/local/sbin to the path, so it is already there the next time? (I use debian ...
0
votes
1answer
189 views

Executable not found although in PATH

My $PATH is set to a lot of directories including ~/bin and ~/target/bin I want to execute script.sh which is in ~/target/bin but I get the error bash: ~/bin/script.sh: No such file or directory ...
0
votes
0answers
52 views

which program is really running?

I am running a self-compiled version on python2.7, --prefix=$HOME, so as not to interfere with the standard installation of python2.6 (on Ubuntu 10.04). Had some problem importing the ssl modules, ...
0
votes
2answers
346 views

How to make scripts run from anywhere on OS X?

I've correctly added my scripts folder to my $PATH. But I still cannot run the scripts from anywhere by simply calling them. How do I achieve this? Example. If I have ~/scripts/ in my path and in ...
2
votes
1answer
200 views

Can only use some commands as sudo

I have had a bit of a problem with some commands lately, not working as intended. I wanted to fiddle with some Markdown and try it as a substitute for some simple HTML pages, so I looked into some ...
0
votes
2answers
249 views

How to permanently reset my $PATH?

I was trying to add something to $PATH and it went totally wrong. I now can't run any commands such as ls. I've looked at this answer ...
1
vote
0answers
346 views

Faking a Linux environment without chroot

For a university project I want to test a C++11 program on a 32-core machine. Unfortunately the machine has Ubuntu 12.04 with GCC 4.6 installed (we need GCC 4.7 because of some C++11 threading ...
0
votes
2answers
126 views

How to get ~/foo from /home/user1/foo?

The Bash prompt supports the \w escape sequence, documented as \w the current working directory, with $HOME abbreviated with a tilde (uses the value of the PROMPT_DIRTRIM variable) Is ...
0
votes
2answers
287 views

Unix list absolute file name

Given an arbitrary single argument representing a file (or directory, device, etc), how do I get the absolute path of the argument? I've seen many answers to this question involving ...
0
votes
1answer
363 views

Mac OS X 10.6 executable not found without full path

I just installed Apache via MacPorts. It seems that my Mac was absolutely confused about which version of the Apache executables to run. After moving the Apache executables that ship with the Mac to ...
0
votes
1answer
196 views

x-terminal-emulator not getting path

I have a script that uses x-terminal-emulator to launch a different script in a new terminal window. I am using ubuntu 12.04 and a colleague of mine is using ubuntu 12.10 and this is not working for ...
0
votes
0answers
18 views

Where is my $PATH declaration in OSX Snow Leopard? [duplicate]

Possible Duplicate: Where does $PATH get set in OS X 10.6 Snow Leopard? When I run echo $PATH in Terminal this is the result: house@The-iMac:~$ echo $PATH ...
0
votes
1answer
595 views

command not found even though directory is in $PATH [closed]

I'm having trouble running a program which should be on my $path, but apparently isn't. When I run it with the full path, it works fine, but when I only call the executable, it says command not found. ...
2
votes
1answer
1k views

Messed up $PATH variable in Mac OS X

I did something to my PATH. I was trying to add some new path and now none of the command like open ~/.bash_profile work, and echo $PATH only shows one path which is /Application/Filename. Is ...
1
vote
1answer
39 views

Why is which not matching the effect I get?

I cannot explain the following behavior: [centos4x64 ~] /usr/local/bin/gmake --version GNU Make 3.82 Built for x86_64-unknown-linux-gnu Copyright (C) 2010 Free Software Foundation, Inc. License ...
2
votes
2answers
522 views

How do I find out where paths in my $PATH were defined?

There are some paths in $PATH, which I don't want. I'm not sure how they got there; they aren't coming from my .profile. Is there a way to determine which scripts are modifying $PATH?
0
votes
1answer
749 views

need help cleaning out my Path Variable in Mac

when I typed $PATH i noticed a jungle -bash: ...
1
vote
2answers
1k views

separate file and path in bash?

How can I separate the path and file elements in a bash loop like this? for file in `find /my/path -name "*.ext"` do #(path,onlyfile) = separate_path_and_file $file #dosomethingwith $onlyfile ...
0
votes
2answers
2k views

Can't access Terminal anymore, only shows a cursor

I run OS X. Following these directions (Installing MySQL on Mac OS X) I added a file to /usr and the contents were PATH=/usr/local/mysql/bin:$PATH Actually I was trying to get the mysql command ...
2
votes
2answers
311 views

Getting “export PATH” to stick

I just upgraded to Lion and I am using bash for the first time (my previous experience is with csh and tcsh). I have encountered unexpected behavior. A simple example is: I create a file ...
1
vote
1answer
1k views

brew doctor giving error on a directory that has been removed

I just installed homebrew and as suggested, I ran the brew doctor command. I am linux newbie and do not know how to fix most of these things. But I would like to ask especially about the following ...
1
vote
1answer
157 views

Get part of script run directory in bash

I'm running a Bash script that's buried in a directory on my system. I need to be able to get the first section of the directory path. The path returned by $0 in my script is as below. The ...
0
votes
1answer
469 views

How do I execute my script by just typing its name?

I have a script in /home/username/scripts and I would like to execute it by just typing its name. I know I could do 'export PATH=$PATH:/home/username/scripts' but I would like to have the same ...
2
votes
3answers
1k views

how to remove path of my command line?

When I start to enter in different folder the path is registered in my command line and I don't know how to remove it. I am almost sure my question wasn't clear. An example is always better. Once in ...
13
votes
2answers
15k views

Environment variables in bash_profile or bashrc?

I have found this question [blog]: Difference between .bashrc and .bash_profile very useful but after seeing the most voted answer (very good by the way) I have further questions. Towards the end of ...
0
votes
4answers
1k views

Can't add executable file to PATH in Linux

I have this in my ~/.bash_profile: PATH=$PATH:~/Downloads/sublimetext export PATH But sublimetext in the folder isn't added to the path. Sublime Text gives this output when submitted to the ...
3
votes
2answers
2k views

How can I find out where an environment variable (like PATH) was set?

I have a xterm with the bash shell in linux. When I echo $PATH, it is showing a directory and I want to know who put this directory in the PATH. How can I find out? Thanks!
5
votes
1answer
3k views

export PATH= not holding in Bash OS X

This is somewhat of a noob question but I'm having problems adding to my path and can't remember how I got changes working the last time I did it. So I'm using the command "export ...
1
vote
1answer
166 views

How do I create a command to run with sudo?

I have created a file called svrestart in /home/gab/bin (which is a folder that should be automatically be added to path on startup) which contains: /etc/init.d/nginx restart /etc/init.d/php5-fpm ...
1
vote
0answers
144 views

Why my $PATH is not inhereted by the invocked bash? [closed]

I work on an AIX system where I have no administrator privileges. It has several shells installed, default being tcsh. I am not allowed to change the login shell. Usualy I start my session from exec ...
10
votes
1answer
19k views

How to permanently add current directory to PATH in Linux? [duplicate]

Possible Duplicate: Add folder to PATH I want to a add a directory to my bash to search in, and I am using the $PATH=.... it works however when I open a new command window it is not there. ...
3
votes
1answer
162 views

Why does ~username/ change to /home/username if tab-completing a path with a space in it?

In ~jacksonc/temp/ there are two files, test.txt and space test.txt, both placed there through Windows (using Samba). Using bash, if I type cat ~jacksonc/temp/t[tab] , it autocompletes to cat ...
0
votes
2answers
764 views

how did git add itself to the PATH on OSX 10.6 ? It's not in bashrc or profile? [duplicate]

Possible Duplicate: How do I set PATH and other environment variables? I recently installed git 1.7.4.4 via the installer from here http://code.google.com/p/git-osx-installer/ (not via ...
2
votes
1answer
698 views

Bash autocomplete paths “through” environmental variables

I used to be able to type cd $home/p hit the tab key and the command would change to cd /home/phill Now it doesn't. When cd'ing to a directory based on an environmental variable, I'm "flying ...