I'm trying to nest commands in a script file so that I can do an if
checking in one command. Here's the command thus far:
if ((`/bin/hostname | fgrep -c mirror` == 1) && `(((finger | grep
"whoami") | grep "tty | cut -c9-11") | fgrep -c vortex)` != 0) then
As can be seen, even with the parentheses, the shell doesn't like it.
It won't ever run the inside when it is supposed to. The problem seems
to be that when it fingers, it greps for the string "whoami", not for
the string returned if one ran "whoami". But since the finger is itself
enclosed in backquotes, how does one quote the whoami such that it
Please E-mail or CC all responses to facilitate things, or I might miss them.
---===<<<(((### -=Todd Gleason=- -=Cool-Man=- ###)))>>>===---
From computer arguments to the love of women, as far back as the dawn of
Cal-Clue-Less to the future of balloons, with music arcane and actions
forbade, for the Command Chair and the glory of Ramen, this is ME, and
these are the times upon which the greatest of sagas shall be written. . . .