LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   where to put global alias' (http://www.linuxquestions.org/questions/slackware-14/where-to-put-global-alias-128708/)

true_atlantis 12-24-2003 04:54 PM

where to put global alias'
 
in mandrake i used ~/.bashrc to create global aliases for certain commands. where should i put them in slack?

GATTACA 12-24-2003 05:38 PM

in the same place.

true_atlantis 12-24-2003 05:48 PM

the ~/.bashrc file does not exist... i created it, but it still will not work....

for example, i added this line to my ~/.bashrc

alias dir="ls -al"

then saved and did a

source ~/.bashrc

then i typed dir, and it worked fine... but i closed the konsole, and opened a new one, and when i typed dir, it did not do the same thing it did before.....

GATTACA 12-25-2003 10:47 AM

Hmm... I think I got around this problem by adding a command to my ~/.profile or ~/.bash_profile file. I just added the line: source ~/.bashrc
to one of these files.
As an alternative checkout what I posted here:
http://www.linuxquestions.org/questi...threadid=39619

HTH

true_atlantis 12-25-2003 03:31 PM

thanks... what i ended up doing is adding this line to /etc/profile

source ~/.bashrc

and now each user must create a ~/.bashrc with watever they want in it...


All times are GMT -5. The time now is 03:12 PM.