You're missing backquotes (the ``), that way you tell script to execute whatever is in backquotes and use its result.
Examples:
$ echo date
$ echo `date`
$ echo cat /etc/pf.conf
$ echo `cat /etc/pf.conf`
Again see killasmurf's post carefully.
EDIT: There you go, one has to be fast around here!
__________________
The best way to learn UNIX is to play with it, and the harder you play, the more you learn.
If you play hard enough, you'll break something for sure, and having to fix a badly broken system is arguably the fastest way of all to learn. -Michael Lucas, AbsoluteBSD
|