martes, 11 de enero de 2011

Alias in Linux

Here a simple way to create a simple name to execute a repetitive command:

You can open you .cshrc
nedit ~/.cshrc

Type in this file the following:

alias copyNow 'cp /home/username/file.xml /home/username/MyDir'

Finally compile this file
source ~/.cshrc

From now on whenever you type in any terminal

copyNow

the file file.xml will be copied in MyDir.

Many possibilities here!!

No hay comentarios:

Publicar un comentario