Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
New OmniFocus Task
import webbrowser
import urllib
# omnifocus:///add?name=[prompt]&note=[prompt]
omnifocus_url = "omnifocus:///add?"
task_name_url = "name="
note_url = "note="
# input
prompt = "> "
task = raw_input("Task: \n" + prompt)
note = raw_input("Note: \n" + prompt)
# url encode
task = urllib.quote(task)
note = urllib.quote(note)
# open in omnifocus
webbrowser.open(omnifocus_url + task_name_url + task + "&" + note_url + note)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.