Aliases

Author

Marie-Hélène Burle

Aliases are a convenient way to assign a custom command to a name. You can use new names or re-assign existing command names.

alias myip="ip -json route get 8.8.8.8 | jq -r '.[].prefsrc'"
alias ls='ls -F'

You can retrieve the definition of an alias by running the alias command without argument. To remove an alias, use unalias.

You can use the non-aliased version of a command with \ (e.g. \ls).