Skip to content

Instantly share code, notes, and snippets.

@znake
Created June 18, 2012 16:44
Show Gist options
  • Save znake/2949342 to your computer and use it in GitHub Desktop.
Save znake/2949342 to your computer and use it in GitHub Desktop.
Connect to your favorite VPN on Startup
tell application "System Events"
   tell current location of network preferences
       set VPNservice to service "Name of my favorite VPN" -- name of the VPN service
       if exists VPNservice then connect VPNservice
   end tell
end tell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment