[UCLA-LUG] $PATH
Frederick Lee
phaethon@fire.csua.ucla.edu
Thu, 4 May 2000 12:17:40 -0700
On Thu, 04 May 2000 00:26:43 -0700, said Namson Tran <namson@ucla.edu>:
>Where is the PATH variable absolutely declared? Everywhere I look, I see a
>reference to $PATH, but no place where PATH is actually defined. Thanks for
>any help in advance.
>
>namson
GNU bash has a built-in "absolutely minimal" PATH setting. This is
configurable when the shell is being compiled (e.g. by the vendor for
a binary distribution); due to Unix patterns, the most common built-in
PATH is "/bin:/sbin:/usr/bin:/usr/sbin" (or something along those lines).
Site-specific settings are in /etc/profile and/or /etc/bashrc. If PATH
isn't set in these, bash will keep its builtins.
User-specific settings are in ~/.bash_profile, ~/.bashrc, and/or ~/.profile.
IIRC, these files inherit the settings from the site-wide files.
-Fred