robwalton Posted October 10, 2016 Share Posted October 10, 2016 (edited) I've put an Alfred workflow for TaskPaper 3 up at packal and github. The page includes a download link, full instructions and an image. Please give it a go. There is a is another discussion thread on the TaskPaper forum. The commands are briefly: Keywords: - d:setdoc - configure the TaskPapar document - d:choosedoc - configure the TaskPaper document via a dialogue box - d:help - show a brief summary of commands and settings - d:setremind - view, change or disable the reminder search - do - open the workflow’s TaskPaper document - do <task> - create a new task - domail - create tasks from emails selected in Apple’s Mail app - dos - search for and then select an item. Use modifiers cmd to toggle @done and shift to toggle @today tags - dop - search for and then focus on a project - doss - select and apply a search saved from the document - dot - search for and then append a tag to any current search. Use the modifier cmd-return to instead clear the search before appending the tag - dopr - open resources associated with a project or to add a folder or alias resource if none exist - dosn - show (expand) all notes - dohn - hide (collapse) all notes Modifiers: - none - operate on a project - ⌘ - operate on the Inbox - ⇧ - operate on the Stack - ⌥ - operate on the Reading List project The source is on github and the code behind the scenes is written using JXA. Please let me know if you run into troubles or have suggestions. --- Rob Edited April 1, 2017 by robwalton Update with new v1.0 commands Lecter and thec13 2 Link to comment
Lecter Posted October 10, 2016 Share Posted October 10, 2016 I've only tried a few commands, but thus far, it works well. Thanks for making and sharing it! Link to comment
dfay Posted October 11, 2016 Share Posted October 11, 2016 Thanks so much for this. I had something similar cobbled together from others' and my own AppleScript for TP2 but there's no way I was going to have time to update it all in JXA. Link to comment
robwalton Posted October 11, 2016 Author Share Posted October 11, 2016 Thanks for feedback guys. I've put a new version 0.9.1 up at packal.org/workflow/taskpaper . This includes a few improvements: Fix help command to work when no workflow document has been configured Improve d:setdoc command so that it now shows all TP docs before typing Improve dop command to focus on projects properly in all cases Improve search command to now show all items before user starts typing Add autocomplete to script filters and fix icon references Link to comment
robwalton Posted October 11, 2016 Author Share Posted October 11, 2016 15 hours ago, dfay said: Thanks so much for this. I had something similar cobbled together from others' and my own AppleScript for TP2 but there's no way I was going to have time to update it all in JXA. I can see why you wouldn't want to do it a second time! Just noticed TaskPaper 3.5 has been released. Hopefully it will all still work right. I found the Javascript part of JXA okay---it has some oddities but not too bad and way easier to write than Applescript. Also TaskPaper's API where you evaluate code inside it is pretty easy to work with. However, the Apple automation bit of JXA is seems pretty hit and miss. Things that would work in Applescript sometimes don't in JXA or bits are missing; but the good thing about JXA is you can use objective C which seemed to work well. dfay 1 Link to comment
robwalton Posted October 14, 2016 Author Share Posted October 14, 2016 A new version 0.9.1 up at packal.org/workflow/taskpaper. This includes: Quote Fix dop (project) command broken in previous release Disable the remind screen feature by default Add feature to toggle the @done or @today tag via the dos (search) command Link to comment
RobOK Posted October 17, 2016 Share Posted October 17, 2016 This is very much appreciated! Am just starting to use it! Link to comment
robwalton Posted October 27, 2016 Author Share Posted October 27, 2016 (edited) A new version 0.9.3 up at packal.org/workflow/taskpaper. This includes: Quote - d:setdoc now warns if Spotlight finds no TaskPaper files and suggesus d:choosedoc - Create new d:choosedoc command to choose a workflow via a dialogue box - Cursor now correctly moves from sidebar to editor pain when selecting an item - Fix 'do' command with no args to now open workflow doc rather than just bring TP forward - domail command warns if Mail app is closed and no longer creates an empty entry There is a discussion thread on the TaskPaper forum. Edited October 27, 2016 by robwalton Link to comment
marlowe Posted November 27, 2016 Share Posted November 27, 2016 (edited) This is a huge help. I had a lot of Applescripts I made for Taskpaper 2 and Alfred that broke when I upgraded to 10.12, and even though I had upgraded to Taskpaper 3, I was missing a lot of the efficiency I had before due to the loss of my workflows and not having the time to invest yet in relearning how to automate Taskpaper 3. This workflow is great. Thank you for sharing it! Edited November 27, 2016 by marlowe minor edit dfay 1 Link to comment
Lecter Posted December 2, 2016 Share Posted December 2, 2016 I really like the "domail" command for Mail. Being able to put the title of the e-mail and a link to the e-mail into a project is delightful! I noticed that the mail task has an extra line placed after it. Is that extra line there for a reason? Separate topic: Is there a possibility to add the same type of command for URLs? For example, "dou" would copy the title and URL of the front tab in Safari and place them into TaskPaper as a task. I've been trying to code it myself, but thus far, I can't figure it out. Link to comment
robwalton Posted December 10, 2016 Author Share Posted December 10, 2016 On 12/2/2016 at 4:18 AM, Lecter said: I really like the "domail" command for Mail. Being able to put the title of the e-mail and a link to the e-mail into a project is delightful! I noticed that the mail task has an extra line placed after it. Is that extra line there for a reason? Hi @Lecter, Thanks for the feedback. I also use the 'domail' command a lot. The blank lines are a bug which snuck in. It also fails if either Mail or TP is not open, and annoyingly brings in the entire thread rather than just the most recent item. Will fix at some point! On 12/2/2016 at 4:18 AM, Lecter said: Is there a possibility to add the same type of command for URLs? For example, "dou" would copy the title and URL of the front tab in Safari and place them into TaskPaper as a task. I've been trying to code it myself, but thus far, I can't figure it out. This would be a handy feature and if I get my head into working on this again I'll probably add it. It could even copy in any highlighted text. Not totally sure that everyone would get the mnemonic 'dou' though. Link to comment
Lecter Posted December 11, 2016 Share Posted December 11, 2016 1 hour ago, robwalton said: Will fix at some point! Thanks! 1 hour ago, robwalton said: Not totally sure that everyone would get the mnemonic 'dou' though. It was just the first one that came to mind. Please use whichever one suits you! Link to comment
robwalton Posted April 1, 2017 Author Share Posted April 1, 2017 On 11/12/2016 at 0:29 AM, dfay said: This may help with dou Thanks, super useful. Link to comment
robwalton Posted April 1, 2017 Author Share Posted April 1, 2017 I've put a new version 1.0 up at packal and github. This includes some new features: Quote - Added dorl (rl for read later) command to capture active webpage title, URL and highlighted text - Added dosn` and dohn to show or hide notes respectively - Collapse notes in items added by do, domail or dou - Add 'alt' modifier to act on 'Reading List' project @Lecter, dorl (for 'read later') is for you! There is a slightly more active discussion thread on the TaskPaper forum. Lecter 1 Link to comment
Lecter Posted April 1, 2017 Share Posted April 1, 2017 3 hours ago, robwalton said: @Lecter, dorl (for 'read later') is for you! Thank you @RobWalton ! Link to comment
msdisme Posted December 31, 2017 Share Posted December 31, 2017 Hi Rob, If I have questions abou tht eworkflow what is the best way to ask them? Thanks! Michael Link to comment
robwalton Posted December 31, 2017 Author Share Posted December 31, 2017 12 hours ago, msdisme said: If I have questions abou tht eworkflow what is the best way to ask them This forum is a good place to ask questions. I'm not always that active, but seem to be ramping up again. I'm also likely to start using TaskPaper again, so that might help. Link to comment
gerbenzaagsma Posted July 3, 2019 Share Posted July 3, 2019 Hi Rob, It seems the upgrade to Alfred 4 breaks this workflow; you might have abandoned Alfred and the workflow but if not perhaps you might have a look? All best wishes, Gerben Link to comment
Vero Posted July 4, 2019 Share Posted July 4, 2019 @gerbenzaagsma It looks like this workflow has a hardcoded reference to Alfred 3, which may be one of the issues. I'm also seeing a "Spotlight can't find any TaskPaper documents" error when using d:setdoc, but it works fine when using d:choosedoc and manually selecting a file. @robwalton may be able to shed more light on this. Once your document is chosen, it seems to work as expected (though I've only just tried the workflow and may not have tried every keyword yet) If you experience other issues, take a look at the debugger (https://www.alfredapp.com/help/workflows/advanced/debugger/) as suggested in my earlier email reply to you. This will then give Rob (and the community) more information to help tweak this workflow. Cheers, Vero Link to comment
patto Posted August 7, 2019 Share Posted August 7, 2019 @gerbenzaagsma @Vero I also had this issue - I edited the calls.scpt file to update the hard ref from: var DATA_PATH = $.getenv('HOME') + '/Library/Application Support/Alfred 3/Workflow Data/' + WORKFLOW_NAME to: var DATA_PATH = $.getenv('HOME') + '/Library/Application Support/Alfred/Workflow Data/' + WORKFLOW_NAME did d:choosedoc once more, and then all worked fine Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now