Skip to content

Instantly share code, notes, and snippets.

@mactkg
Created January 16, 2013 16:55
Show Gist options
  • Save mactkg/4548780 to your computer and use it in GitHub Desktop.
Save mactkg/4548780 to your computer and use it in GitHub Desktop.
#!/bin/sh
ADDRESS=`grep OFFER /var/log/system.log | tail -n1 | cut -d' ' -f9`
if test -z $1
then
ssh pi@$ADDRESS
else
ssh $1@$ADDRESS
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment