On Thu, Mar 27, 2008 at 2:20 PM, Hongzheng Wang <[EMAIL PROTECTED]> wrote:
>  I have a question about the settings in p9p (plan 9 from user space),
>  such as setting the default font ($font).

 Wherever you want. The environment is not something p9p specific, and
how it gets initialised in somewhat dependent on your shell, OS, and
distribution.

>  According to the documents, $PLAN9/rcmain and $home/lib/profile are
>  two places to put configurations stuff, say environments etc, which
>  would be read by rc shell when invoked by `-l' option.  But it is not
>  convenient if we use default shell, say Bash, instead of rc.

 You're right, rc is beautifully simple compared to bash.
 It goes something like this:
 bash login shell: reads /etc/profile and ~/.bash_profile
 bash interactive non-login shell: reads ~/.bashrc
 bash non-interactive non-login shell: reads nothing unless you've set BASH_ENV.

 If you run /bin/sh instead of /bin/bash these rules totally change.
You'll find the details in bash(1) (maybe).
-sqweek

Reply via email to