nroberts420
Programmer
I am having a really hard time getting the path in my .bash_profile file set so I can run all the commands in /sbin from the command line with out having to supply the path. My .bash_profile file looks like this:
# .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
PATH=$PATH:$HOME/bin:/sbin
export PATH
echo $PATH
unset USERNAME
I assume this should work because if I run the command PATH=/sbin:$PATH from command line then everything works. Just for some reason not from the .bash_profile file.
Nate
# .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
PATH=$PATH:$HOME/bin:/sbin
export PATH
echo $PATH
unset USERNAME
I assume this should work because if I run the command PATH=/sbin:$PATH from command line then everything works. Just for some reason not from the .bash_profile file.
Nate