screen-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Reattaching to a detached screen


From: Michael Grant
Subject: Re: Reattaching to a detached screen
Date: Thu, 1 Jan 2009 23:08:24 +0100

Here is what I use in my .bash_login:

if screen -wipe 2>&1 | egrep -v "No Sockets found" >/dev/null; then
  echo -n "Reattach to detached tree? (y/n) [space=y] "
  read -n1 a;
  if [[ ("$a" = "y") || ("$a" = "") ]]; then
    exec screen -xRR
  fi
  echo ""
else
  echo "type 'screen' to start screen"
fi


It's simple and effective and reminicent of the old TOPS-20 and ITS days.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]