Monday, March 16, 2009
Listing the configured aliases on my box.
alias mc='. /usr/share/mc/bin/mc-wrapper.sh'
alias rm='rm -i'
As you can see, rm is aliased as 'rm -i' (i.e. prompt before every removal)
So if you try to remove any file using 'rm', its going to prompt you for confirmation.
$ rm file.txt
rm: remove regular empty file `file.txt'? y
Now if you want the use 'rm' command without the alias additions (rm -i), you have two ways:
Unaliasing a command by simply prefixing the command with a \
$ \rm file.txt
Other alternative: Using unalias command
$ unalias rm
The above 'rm' one is just an example to illustrate this, (you can also do 'rm -f' for the same :-))
© Jadu Saikia www.UNIXCL.com