What makes RedHand such a versatile applicaton is the fact that it allows execution of arbitrary programs when certain events are encountered. A program is anything that can be executed, including Shell scripts and AppleScript.


To give you a simple example, this script plays a sound as loud as possible. The system volume is restored afterwards.

set volume_old to output volume of (get volume settings)
set volume output volume 100
do shell script "afplay '/System/Library/Sounds/Submarine.aiff'"
set volume output volume volume_old

Send email w/ photo

This script will send the photo taken by RedHand to an email address. It takes the path and file name of the photo as its sole argument.

on run image
set recipientName to "Joe User"
set recipientAddress to ""
set theSubject to "Intrusion Attempt"
set theContent to "RedHand detected an intrusion attempt: " & image
set img to POSIX path of image

tell application "Mail"
set theMessage to make new outgoing message with properties
{subject:theSubject, content:theContent, visible:true}

tell content of theMessage
make new attachment with properties {file name:img} at after last paragraph
end tell

tell theMessage
make new to recipient with properties {name:recipientName, address:recipientAddress}

end tell
end tell
end run

Just replace the name (recipientName) and email address (recipientAddress) in the script. The command line argument needs to be provided by RedHand, so configure it like this:

Also make sure you tell RedHand to actually take a photo, when the event occurs.