Skip to content

Instantly share code, notes, and snippets.

@qingfeng
Created January 27, 2011 01:30
Show Gist options
  • Save qingfeng/797895 to your computer and use it in GitHub Desktop.
Save qingfeng/797895 to your computer and use it in GitHub Desktop.
Production is Red
#!/bin/sh
export R=$1
export G=$2
export B=$3
/usr/bin/osascript <<EOF
tell application "Terminal"
tell window 0
set the background color to {$(($R*65535/255)), $(($G*65535/255)), $(($B*65535/255))}
end tell
end tell
EOF
#!/bin/sh
for s in server1 server2 server3
do
if [[ "$@" = "$s" ]]; then
~/tools/bg_color.sh 20 0 0
fi
done
ssh $@
~/tools/bg_color.sh 0 0 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment