Take the 2-minute tour ×
Ask Different is a question and answer site for power users of Apple hardware and software. It's 100% free, no registration required.

I wrote an AppleScript to mount a bundled sparse disk image. I want this script to be executed exactly when Time Machine launches.

I can check if Time Machine is running with on idle statement,

on idle
    ....
    return <interval>
end idle

but I'm pretty sure, it isn't a robust way to do that.

IMO making an event trigger for Application Launch event would be a better approach.

I appreciate if someone can help me.

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

You can use a LaunchAgent (see Lingon) to perform an action when a file is modified. Time Machine has some file somewhere that it modifies each time it starts.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.