Skip to content

Instantly share code, notes, and snippets.

@jwhitley
Forked from robjwells/Restart in Windows.applescript
Last active November 10, 2016 16:23
Show Gist options
  • Save jwhitley/8377268 to your computer and use it in GitHub Desktop.
Save jwhitley/8377268 to your computer and use it in GitHub Desktop.
set deviceID to (do shell script "diskutil list | awk '/YourBootcampPartition/ {print $NF}'")
do shell script "sudo bless -device /dev/" & deviceID & " -legacy -setBoot -nextonly"
tell application "Finder" to restart
@robjwells
Copy link

That’s a neat solution, nice work John.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment