Go to the first, previous, next, last section, table of contents.


Functions

A function is similar to an alias in usage. If the first word of a simple command is unquoted and is the name of a function, the function is run with the arguments to the simple command as positional parameters. The difference is that rather than being stored as a textual string as is the case with an alias, a function is stored in a tokenised form which allows it to be executed somewhat faster than an alias. As a general rule, anything that extends over more than one line should be defined as a function, not an alias.


Go to the first, previous, next, last section, table of contents.