Created
October 13, 2012 19:01
-
-
Save zthomae/3885770 to your computer and use it in GitHub Desktop.
Shell scripts for remote screen on ec2
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 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 " | |
| screen -t shell 0 | |
| screen -t irc 1 | |
| screen -t code 2 | |
| screen -t etc 3 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| orig=`/usr/X11R6/bin/xprop -id $WINDOWID | perl -nle 'print $2 if /^WM_NAME.+= "(.*)"$/'` | |
| if [ -z $orig ]; | |
| then | |
| orig=`hostname` | |
| fi | |
| echo -e "\033]2;$1\007" | |
| ssh -i $1 -t $2 screen -S main -xRR -p $3 -q | |
| echo -e "\033]2;$orig\007" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment