whatis alias

Alias

A shell shortcut that replaces a short name with a longer command, such as alias ll='ls -lah'.

What Is an Alias in Linux?

Aliases are expanded by the shell before the command runs. They are handy for flags you always use, but they only work in interactive shells and only for the first word of a command.

Define them in ~/.bashrc or ~/.zshrc to make them permanent. For anything that needs arguments in the middle or logic, write a shell function instead. \ls or command ls bypasses an alias.

Example

alias ll='ls -lah'
alias | grep ll