Skip to main content

Posts

Showing posts with the label aliases

alias: replace your lengthy commands with shorter ones

Create an alias, aliases allow a string to be substituted for a word when it is used as the first word of a simple command. Syntax alias [-p] [ name [= value ] ...] unalias [-a] [ name ... ] Key -p Print the current values -a Remove All aliases If arguments are supplied, an alias is defined for each name whose value is given. If no value is given, `alias' will print the current value of the alias. Without arguments or with the `-p' option, alias prints the list of aliases on the standard output in a form that allows them to be reused as input. name may not be `alias' or `unalias'. unalias may be used to remove each name from the list of defined aliases. Examples Create an alias 'ls' that will actually run 'ls -F' $ alias ls='ls -F' $ ls $ unalias ls $ alias la='ls -lAXh --color=always' #Show all, sort by extension $ alias ls-al='ls -al' #fix typo missing space $ alias l="ls -l" $ alias la=...