ps | head -2 | tail -1 | grep pts
If the following returns a line, it means that you're current session
is running through a pseudo-terminal.
~Deepak
On May 16 2001, at 16:07, Steven M. Klass was caught saying:
> Hey all,
>
> Does anyone know a way to determine (in bash) if a user is comming from a
> locally or remotely (ssh || rlogin || telnet etc..)?
>
> My .bash_profile is getting FAT!!
>
>
> --
>
> Steven M. Klass
> Physical Design Engineering Manager
>
> Andigilog Inc.
> 7404 W. Detroit Street, Suite 100
> Chandler, AZ 85226
> Ph: 480-940-6200 ext. 18
> Fax: 480-940-4255
>
> sklass@andigilog.com
> http://www.andigilog.com
> ________________________________________________
> See http://PLUG.phoenix.az.us/navigator-mail.shtml if your mail doesn't post to the list quickly and you use Netscape to write mail.
>
> PLUG-discuss mailing list - PLUG-discuss@lists.PLUG.phoenix.az.us
> http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss
--
Deepak Saxena -
deepak@csociety.purdue.edu - phone://602.790.0500
MontaVista Software, Inc. - Powering the Embedded Revolution -
www.mvista.com
call me 'evil' call me 'tide is on your side' anything that you want
anybody knows you can conjure anything by the dark of the moon
- Tori Amos, "Suede"