Shirt Pocket Discussions

Shirt Pocket Discussions (
-   General (
-   -   YASQ (Yet Another Script Question) (

Maxy 03-16-2006 05:28 AM

YASQ (Yet Another Script Question)

First the usual "bravo" stuff for the SD product...

Now to the question: A (new?) feature in the advanced options of SD 2.1 is the ability to run shell scripts before and after a scheduled (for example) backup.

We've seen a lot of questions in the forum related to mounting and unmounting scripts for backup partitions. I don't ask for another version of such scripts, but...

I do intend to mount the backup partition before the backup and to unmount it after. Is the use of the built-in mechanism of SD to call shell scripts before and after the backup a good idea (diskutil -list takes some time to "wake up" my external firewire disk holding the backup partition...) to mount the backup partition before the backup is undergone?

Optional question: what if my shell scripts calls some applescripts (with easier logging and error catching options, even if the applescript call shell scripts)?

Thanks in advance for any answer


Cuneyt 03-16-2006 08:04 AM

Since SuperDuper! does not start to copy if the target drive was not mounted, I suppose, the script which would mount the drive won't help. An Applescript may be used for this purpose to mount the drive and open the SuperDuper! afterwards.

Of course, your shell scripts can call applescripts. For example, I created an applescript to make some cleanup just before SuperDuper! starts copying. This applescripts called by a shellscript which is set to run before SuperDuper's copy.

Maxy 03-16-2006 10:37 AM

Thank you for making clear one of my implicit questions which was: will a scheduled backup proceed at least through the running of the "before script" even if the target partition is not mounted yet, and then, after it is mounted (by the script) be able to backup...

The question remains open, even if you skepticism seems justified to me...


dnanian 03-16-2006 11:03 AM

Sorry, Maxy -- I didn't reply because Cuneyt had it exactly right. If you want to mount/unmount, you'll need to modify the scheduling scripts, because those run before the settings are loaded (and after things are done). The shell scripts inside SD! itself occur too late for this purpose.

richardl 03-16-2006 11:42 AM

This is a really good idea to safe guard the backup (keep it unmounted .. mount it for the backup and then umount) .. Is it possible to add this capability to SD?

Maxy 03-16-2006 12:01 PM

OK. Thanks for the answer. I'll just have to build something inspired by this very interesting thread ...


dnanian 03-16-2006 12:16 PM

It's something we're investigating -- anything's "possible", of course! It's a question of whether it's a good thing to do, and whether it can be expressed appropriately in the UI without confusion.

dnanian 03-16-2006 12:18 PM

Yes -- Dave has a lot of good ideas in there, so I'm sure you'll be able to piece something together.

All times are GMT -4. The time now is 11:17 PM.

Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2021, vBulletin Solutions, Inc.