You are not logged in.
Here's the situation,
When i am at home i like to start xorg upon login so i ve added the following line at the bottom of my .profile
startxWhat i would like to achieve is when i try to ssh my box remotely, i want that line ignored. is there anyway to do this?
thank you all
Last edited by sparky (2012-02-17 14:53:12)
Offline
This might work, but I would put it in $HOME/.bashrc, not in $HOME/.profile:
Put it somewhere near the end of .bashrc
function ontty1 ()
{
RESULT=$(tty|sed 's/\/dev\///');
[[ $RESULT == 'tty1' ]] && return 0 || return 1
}
if ontty1; then startx; fihth
bootinfoscript - emacs primer - I ♥ #!
Offline
awesome! thank you 
Offline
Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.