I fiddled a bit more and looked at
this site to get a bit more info and I have cobbled
cjlemonier's script together with the one at the link.
Now you just need to activate the script and it will sync the phone and mac and 'cut' the todos synced from the phone/iCal to do list and paste them into the Omnifocus inbox. The other change is that this now activates iSync if it wasn't running and then closes it after the script has run.
Here it is, again be careful anyone else running this because this will delete todos from iCal.
Code:
tell application "System Events"
set iSyncIsRunning to (count of (every process whose name is "iSync")) > 0
end tell
tell application "iSync"
activate
synchronize
-- wait until sync status != 1 (synchronizing)
repeat while (syncing is true)
end repeat
set syncStatus to sync status
set lastSync to last sync
end tell
tell application "iCal"
set theCalendars to every calendar
repeat with theCalendar in theCalendars
set theTodos to every todo in theCalendar
repeat with theTodo in theTodos
set theTodoSummary to summary of theTodo
tell application "OmniFocus" to tell default document
make new inbox task with properties {name:theTodoSummary}
end tell
delete theTodo
end repeat
end repeat
end tell
if syncStatus = 2 and not iSyncIsRunning then
tell application "iSync" to quit
end if
This is my first applescript and there are possibly errors or bad practices in the way that I've done this but it seems to work for me.