Contents:
Creating Custom Commands
Aliases for Common Commands
C Shell Aliases with Command-Line Arguments
Aliases in ksh and bash
Sourceable Scripts
Avoiding C Shell Alias Loops
How to Put if-then-else in a C Shell Alias
Fix Quoting in csh Aliases with makealias and quote
Shell Functions
Simulated Bourne Shell Functions and Aliases
In most shells, aliases ( 10.2 , 10.3 , 10.4 ) are an easy way to shorten a long command line or do a short series of commands.
All except the oldest Bourne-type shells have shell functions ( 10.9 ) . These are a cross between aliases and shell scripts. They're good both for shortening command lines and for running a short or long series of commands.
You can simulate shell functions ( 10.10 ) on older Bourne shells. These "fake functions" don't have much more power than aliases - but they're better than nothing!
-