Here's the script I used to use - it's a slightly modified version of one by Ralf Niedling. Paste the code into Applescript Editor, compile and save as RecordingDone. You'll need to change the destination path first and create a custom profile in the Turbo.264 software (mine is a custom profile called iPad2):
(*Export Script for the export of EyeTV recordings with Turbo.264 HD by selecting a custom profile. Please copy this script to
"/Library/Application Support/EyeTV/Scripts" and also to "/Library/Application Support/EyeTV/Scripts/TriggeredScripts" . Then it
will start Turbo.264 HD after recording has finished and convert the recording with custom profile (iPad2 in this case)
and save the output file in folder DEST_PATH
Most work done by Ralf Niedling (
http://www.niedling.info ).
property SOURCE_TYPE : ".mpg"
property DEST_PATH : "/Volumes/MediaFW/iTunes/Automatically Add to iTunes"
on RecordingDone(recordingID)
tell application "EyeTV.app"
set new_recording_id to (recordingID as integer)
set new_recording to «class cRec» id new_recording_id
my export_recording(new_recording)
end tell
end RecordingDone
on run
tell application "EyeTV.app"
set selected_recordings to selection of «class Prgw»
repeat with selected_recording in selected_recordings
my export_recording(selected_recording)
end repeat
end tell
end run
on export_recording(the_recording)
tell application "EyeTV.app"
set recording_location to URL of the_recording as text
set AppleScript's text item delimiters to "."
set recording_path to text items 1 through -2 of recording_location as string
set AppleScript's text item delimiters to ""
set recording_path to POSIX path of recording_path
set input_file to recording_path & SOURCE_TYPE as string
tell application "Turbo.264 HD.app"
launch
«event TuBoAddf» input_file given «class Etgt»
EST_PATH, «class Etyp»:«constant EtypCust», «class CusN»:"iPad 2"
«event TuBoTenc»
end tell
end tell
end export_recording
on get_recording_name(recording_location)
set oldDelimiters to AppleScript's text item delimiters
set AppleScript's text item delimiters to "/"
set path_components to every text item of POSIX path of (recording_location as string)
set recording_folder to item -2 of path_components as string
set AppleScript's text item delimiters to ".eyetv"
set recording_name to first item of every text item of recording_folder
set AppleScript's text item delimiters to oldDelimiters
return recording_name
end get_recording_name
on escape_path(the_path)
set oldDelimiters to AppleScript's text item delimiters
set AppleScript's text item delimiters to "/"
set path_components to every text item of the_path
set AppleScript's text item delimiters to oldDelimiters
repeat with counter from 1 to count path_components
set path_component to item counter of path_components
set item counter of path_components to my escape_string(path_component)
end repeat
set AppleScript's text item delimiters to "/"
set the_path to path_components as string
set AppleScript's text item delimiters to oldDelimiters
return the_path
end escape_path
on escape_string(the_string)
set chars to every character of the_string
repeat with i from 1 to length of chars
if "!$&\"'*()/{[|;?` \\" contains (item i of chars as text) then
set item i of chars to "\\" & (item i of chars as text)
end if
end repeat
return every item of chars as string
end escape_string