Bash profiles oh boy:)

Eric Richardson plug-discuss@lists.PLUG.phoenix.az.us
Wed, 16 May 2001 17:13:00 -0700


"Steven M. Klass" wrote:
> 
> 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!!
> 
Look at the utility tty as this returns /dev/pts/x (where x is a number)
at least on a local terminal. I used to use a c fcn isTTY or something
like this to determine whether a program was being run in a terminal or
not.

Hope this helps,
Eric