Linux Commands: Alias

An alias is a shortcut to entering a command in Linux. You can create an alias as shown below.

$ alias ll='ls -l'

If you now enter the command ll, you will get the same output you would have got if you had entered the command ls -l. If you want to add further arguments or flags that is still possible. The command ll -a will for example produce the same output as typing ls -l -a.

To get a list of the current aliases you can enter the command

$ alias

at the command prompt.