Skip to content

Instantly share code, notes, and snippets.

@falsecz
Created June 10, 2015 08:03
Show Gist options
  • Save falsecz/b67f891ce881dc707c99 to your computer and use it in GitHub Desktop.
Save falsecz/b67f891ce881dc707c99 to your computer and use it in GitHub Desktop.
#!/bin/bash
FIRST=0
echo "tell application \"System Events\" to keystroke \"t\" using command down" | osascript
for var in "$@"; do
if [ "$FIRST" = 1 ]; then
echo "tell application \"System Events\" to keystroke \"d\" using command down" | osascript
fi
FIRST=1
echo "tell application \"System Events\" to keystroke \"ssh $var\n\"" | osascript
done;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment