[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: "source" shell commands

From: Peter Dyballa
Subject: Re: "source" shell commands
Date: Sun, 25 Mar 2007 12:33:43 +0200

Am 25.03.2007 um 01:08 schrieb Matthew Flaschen:

Since I only really need JAVA_HOME, I'm just setting that manually with

All you need to do, is to make sure that when you log-in this environment variable gets set. In case of (t)csh it's simple: /etc/ csh.login is probably read, otherwise ~/.login. In case of bash it is more complicated since bash also checks whether this shell is interactive or not, to be a login shell is not the only criterion. You could think of putting JAVA_HOME into /etc/.profile or into / etc/.bashrc or both – or into your private versions ~/.profile and/or ~/.bashrc.

JAVA_HOME probably is an environment variable that is not specific to some user but is of system-wide meaning.

You can check with ps or better pstree (pstree -p $$) how you logged in.

You can put some shell script into some menu, that just prints the environment it sees. When you make this script start with

        #!/bin/csh -f

then this csh does not read in or source any RC files, it really only sees the existing environment and report this to some file.

You can also put

        echo "something specific"


        echo "something specific" > some specific file or /dev/console

to be informed which RC files are used during a particular action, or menu driven event.



If you're not confused, you're not paying attention.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]