LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   export command (https://www.linuxquestions.org/questions/linux-software-2/export-command-796707/)

brgsousa 03-20-2010 12:36 PM

export command
 
Hi,
in Debian, which is the correct file to add export commands like:
export APXS2=/opt/apache2/bin/apxs
so that the command be executed by OS initialization

thanks

theNbomr 03-20-2010 07:10 PM

Those commands are not executed by the OS. They are executed by the command shell (at least if it is Bourne style shell, like bash), under certain circumstances. If you want all users to have the same commands invoked each time they start a new shell, then you can put them in /etc/bashrc. If you only want them to be established for your own userId, then the ~/.bashrc file is the right place. Any new shell that is launched thereafter will read and set the new values. If you want to have an existing shell to re-read the settings, you can
Code:

source ~/.bashrc
This should always work, since ~/.bashrc for each user normally calls the global bashrc file.

--- rod.


All times are GMT -5. The time now is 09:34 AM.