The task I am trying to do should be reasonably easy. I send emails to myself with a tag in the subject that allows Mail.app to detect these emails and save them as raw email files on the Desktop.
A KM macro runs my custom script that extracts attachments from the emails and saves them to a specific folder, and emits an OmniFocus URL that will create a task named the subject of the email, and the notes of the task contain file URL links that I can click to go to the file in Finder to review/read.
I want the task to be in a project called “Medical” in the folder “Reading”. I can just specify the project as “Medical” because it’s the only project with that name, but if in the future I create another “Medical” project in a different folder, OF will not know where to create the task.
The OmniFocus URL looks like this:
omnifocus:///add?name=<email subject>&project=Medical&autosave=true¬e=<file urls>
where obviously the content of the angle brackets is appropriately filled in based on then email
This works fine, but I don’t know how to specify the folder path to the project in the URL.
I have not found anything via the OF website or The Google.
I had thought that something like Folder>Project would work, but that just creates a new project at the top level called “Folder>Project” so presumably some other mechanism is needed.
The last documentation I can find of this URL scheme is for OF version 2 (I’m of course on 3, eventually going to 4).
I can solve this problem with some AppleScript where I find the appropriately named folder and the project in that folder, and then get the project ID and use that instead, but that seems more inelegant.