And after waking up, try to mount the backup disk again.
So save this as ~/bin/nap and make it executable by casting the spell chmod u+x ~/bin/nap from the terminal.
#!/bin/bash
diskutil unmountDisk /dev/disk1
osascript -e 'tell application "Finder" to sleep'
diskutil mountDisk /dev/disk1
diskutil unmountDisk /dev/disk1
osascript -e 'tell application "Finder" to sleep'
diskutil mountDisk /dev/disk1
Didn't think it would be so simple. I guess i'm just bad at googling :)
[via]
[quick highlighter]
No comments:
Post a Comment