$book = '..'?>
include "$book/mh.php"; includeHeader('makcom.html', 'verrep.html'); ?>As you saw in the Section They Won't Always Work, aliases and shell functions can't be used everywhere that command versions can. Sometimes, though -- especially for commands that you'll never use from anywhere except a shell prompt -- an alias or function is all you really need.
To write a command version from this chapter as an alias or function:
alias tscan 'scan -form scan.timely'
When you run a C shell alias, the shell will use any arguments you
type after the alias name as arguments to the command in the
alias. What I mean is, if you use the tscan alias above and
type:
% tscan +reports last:20
the shell will run:
scan -form scan.timely +reports last:20
That alias trick will work with all the command versions in this
chapter that can be done as an alias. When you write a shell
function, though, you need to include the arguments
with $*. Here's tscan as a Bourne shell function:
tscan()
{
scan -form scan.timely $*
}
Most command versions in this chapter can be written as an alias
or function. The prompter version in the Section
Append Text with prompter.nopre and
the send version in the Section
Version of send: push can't because
they're run directly by other MH commands.
includeFooter('$Date: 2006-05-31 15:13:43 -0700 (Wed, 31 May 2006) $',
'OReilly: 1991, 1992, 1995');
?>