Need to eject both source/destination when SD completes
My goal is to eject both the Source and Destination external disks after an SD backup completes. Currently "scheduled copies" are used and work well. The option "On successful completion" provides an option for ejecting the destination disk but not the source. Presumably, I need to write a shell script to accomplish my goal(?) and hoped someone might have already done this since I'm not proficient with scripts. TIA and thanks for SD! Brian
|
You'd have to write a "on successful completion" shell script that ejected the volume in the background, well after the run finishes. Something like:
Code:
#!/bin/bash |
FWIW: writing and implementing a script consisted of the following( YMMV since my situation is simple ):
1. Enter these commands in a text file ( used BBEdit but any text editor should be fine ) diskutil unmount /Volumes/myVolumeName1 diskutil unmount /Volumes/myVolumeName2 2. Save the file with a .sh extension 3. Issue a 'chmod +x' command on the text file to make it executable. 4. Within SD, go to the "Options" "Advanced" tab and designate the shell script to run in the "After copy" section. Works great. Thanks for the nudge Dave. |
In general, you really don't want to:
- Hardwire the names of the volumes here (they're passed in for you) - Issue this while the copy is not complete, which is why I suggested waiting and doing it in the background But, of course, it's up to you! |
All times are GMT -4. The time now is 07:27 AM. |
Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2024, vBulletin Solutions, Inc.