Skip to content

Instantly share code, notes, and snippets.

@amccarty
Last active August 29, 2015 14:07
Show Gist options
  • Save amccarty/4456493ccd880eb9a368 to your computer and use it in GitHub Desktop.
Save amccarty/4456493ccd880eb9a368 to your computer and use it in GitHub Desktop.
Change Terminal.app color scheme when ssh'ing to a remote host
## This assumes the existence of Solar-Dark and Solar-Remote settings profiles
function tabc {
NAME=$1; if [ -z "$NAME" ]; then NAME="Solar-Dark"; fi
osascript -e "tell application \"Terminal\" to set current settings of front w
indow to settings set \"$NAME\""
}
function ssh {
tabc "Solar-Remote"
/usr/bin/ssh "$@"
tabc "Solar-Dark"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment