scripting/aliases
hellow everyone,
does any1 know how to use aliases without having to log out and log in again? thanks alot in advance and happy new year by the way maya |
If I get your meaning you are putting aliases in .bashrc .bash_profile or some other file and having to log out and in again to use them?
What I do is put my aliases in .aliases which gets sourced from my .bashrc file: Code:
. ~/.aliases |
If you include some aliases in e.g .bashrc, save the file and then:
Quote:
|
i am sorry,
but what does .. bashrc exactly mean? |
acripting/aliases
so from what i understand :
i should create a .aliases file but how to "source it" from my .bashrc file ? thx again maya |
Put ". ~/.aliases" in your .bashrc file, like dive said.
". .bashrc" means to source the .bashrc file. You can also run "source .bashrc". FWIW, I put my aliases in my .bashrc file. |
put the this in your .bashrc:
Code:
[[ -f ~/.aliases ]] && . ~/.aliases |
I used to put aliases directly in my .bashrc but I have so many now that I use a separate file. Plus it is easier to source the file from the console if I add any new ones.
|
finally i understand what the dot means , thx
thanks alot for the quick reply
maya |
All times are GMT -5. The time now is 03:50 AM. |