Skip to content

Instantly share code, notes, and snippets.

@peregrinogris
Created March 13, 2013 18:35
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save peregrinogris/5154856 to your computer and use it in GitHub Desktop.
Save peregrinogris/5154856 to your computer and use it in GitHub Desktop.
# screen
which screen > /dev/null
SCREEN=($?)
if [[ -n "$SSH_CONNECTION" && -z "$STY" && "$SCREEN" -eq "0" ]]; then
# Screen is not currently running, but we are in SSH, so start a session
exec screen -D -R
fi
term xterm-color
hardstatus on
hardstatus alwayslastline
startup_message off
termcapinfo xterm ti@:te@
hardstatus string "%{= kG}%-w%{.rW}%n %t%{-}%+w %=%{..G} %H %{..Y} %m/%d %C%a "
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment