HELP : 'finger' succeds

HELP : 'finger' succeds

Post by srd.. » Wed, 03 May 1995 04:00:00



Hi, I am writing a shell script using finger.  I would like to know
with a particular user parameter whether 'finger' succedded in locating
him or not.  The man pages did not help me.  

Can someone give some pointers on this regard.  The real functionality
I want is if finger succedded in locating my man then I print the
results else I go on to search at another host.

Thanks.                                                 Dash.
--
Cheers.                                                         Dash

 
 
 

HELP : 'finger' succeds

Post by Ananda M. K » Wed, 03 May 1995 04:00:00



-> Hi, I am writing a shell script using finger.  I would like to know
-> with a particular user parameter whether 'finger' succedded in locating
-> him or not.  The man pages did not help me.  
->
-> Can someone give some pointers on this regard.  The real functionality
-> I want is if finger succedded in locating my man then I print the
-> results else I go on to search at another host.

   Get the exit status of the "finger" command. If the finger succeds
   the value will be "0" else it will be non-zero.

   For csh/tcsh :: "$status" stores the value of exit status of the last
                   command.

   For sh/ksh/bash:: "$?" stores the value of exit status of the last
                     command.

   Good Luck

--
Ananda M. Kar |(H)458-9754 | URL: http://www.cs.utexas.edu/users/ananda/
------------------------------------------------------------------------
  I am Pentium of Borg , Division is futile , You will be Approximated