Where to put my custom alias?
For both normal user and root user.
Thanks
Where to put my custom alias?
For both normal user and root user.
Thanks
Do you mean the host-alias?
That is in YaST > Network Services > Host Configuration.
I’m using Suse 10.3
hm… Not sure what’s host-alias
Here is what I’m doing
e.g.
alias ping="ping -c 3"
Oh one more thing. Can you tell me the location of the file to edit through command line? I don’t use GUI.
Host alias is your short host-name.
I have no idea what you want to do. There is couple of things called aliases, example the mail aliases in
/etc/aliases
.
Type
man alias
.
The aliases you mean are aliases to the shell (in your case I think bash).
One normally places them in .bashrc (in one’s home directory). But looking through .bashrc I saw that it checks the existence of .alias and then uses that. So
It is of course a trimming of the user’s environment, though every user must do this if he likes so.
ahh!!!
So that’s how it’s done.
Oh, and root does not have .bashrc but creating ~/.alias still works.
Thanks!
I do not exactly know where that .alias is called from, but the fact that .bashrc does call it from outside (you could also place the alias statements inside .bashrc) gave me already the idea that .alias is shared by more partners (e.g. other shells).
BTW see that the .alias inside /root/ is properly preotected. Only rw bits for te owner (root).