Stacks Posted August 17, 2022 Share Posted August 17, 2022 My primary workflow within Todoist and Alfred is to quickly capture any ideas on my mind and put them into my Todoist inbox for later GTD processing, categorization, and labeling during my daily/weekly review sessions. (I use my Todoist Inbox as my single GTD Inbox across all platforms and clients - from Email, phone, camera, etc) I previously used the https://github.com/moranje/alfred-workflow-todoist workflow, but the structured format was offputting, and it began to truncate many of my tasks after the last update (so I would get tasks in my Inbox that only contained half of what I had entered). Since my primary workflow requires fast input of a single entered string, I went looking for a new solution, and I found a great CLI app that adds tasks extremely efficiently here (https://github.com/alanvardy/tod) So, I wrote an Alfred wrapper for it that adds the tasks to the Inbox and makes my workflow much more efficient. I wanted to share in hopes that it is helpful - I'm fairly new at this, so I would love any feedback on the way I did it Workflow can be found here https://github.com/stacksjb/AlfredTodWorkflow (or on Packal once approved) actionjoe 1 Link to comment
vitor Posted August 17, 2022 Share Posted August 17, 2022 3 minutes ago, Stacks said: I'm fairly new at this, so I would love any feedback on the way I did it Took a quick look and nothing is inherently “wrong”, so take these as mere tips for you to pick and choose:The Workflow’s name includes “Rust”. I recommend against that because the language is irrelevant to users. If in the future you need to change the tool to another written in a different language, it won’t match.In the Run Script, you can replace everything with tod -t "${1}", the query assignment is redundant. Also, always quote your variables in Bash and Zsh.Assuming it can be done, shipping the command-line tool with the Workflow is a better experience for users. I don’t think cargo installs to a location Alfred sees by default (the PATH), so further instructions should be required if you’re not shipping the tool.The GitHub repo only includes the packaged Workflow, not the contents. That makes it harder for someone to contribute with a pull request, as you won’t be able to easily see the changes.Let me know if you have specific questions about any of those. Link to comment
Stacks Posted August 17, 2022 Author Share Posted August 17, 2022 Appreciate the Feedback - thank you! I will work to get those updated. On the github repo notes - do you have a guide for how to upload the files? I saw that on other repos, but didn't see a way to export the files from Alfred (only the final .alfredworkflow bundle) Link to comment
Stacks Posted August 18, 2022 Author Share Posted August 18, 2022 Thanks, updated. Two questions: 1) Is there a better way to compile the alfred workflow without manually uploading the release each time? (I saw some Github actions, but wasn't sure how to use them) 2) For my workflow, I need to take the input from the keyword and I want to be able to post a notification with that text (while also passing it to the script input and parsing the output). So, I set the input as a variable, and then used the $1 you mentioned above throughout the script to pass in the input/output of each stage, while then calling input at the end. Is there a better or built-in way of doing that? Link to comment
Ben428 Posted August 18, 2022 Share Posted August 18, 2022 Thank you! This is just what I have been hoping for since I started using Todoist. It is working perfectly for me. Stacks 1 Link to comment
vitor Posted August 20, 2022 Share Posted August 20, 2022 On 8/18/2022 at 1:55 AM, Stacks said: 1) The GitHub CLI allows making releases with attachments from the command-line. On 8/18/2022 at 1:55 AM, Stacks said: 2) Can’t say without looking at the Workflow. Link to comment
erstaples Posted May 25, 2023 Share Posted May 25, 2023 I went through the trouble of creating an account just to say thank you for creating this (and introducing me to the `tod` CLI). This is exactly what I was looking for, and I was hoping I wouldn't have to code my own. Stacks 1 Link to comment
actionjoe Posted June 15, 2023 Share Posted June 15, 2023 Hello there, I just downloaded everything and it totally works! thanks a lot for the workflow However I have a little issue, as I am typing the shortcut into alfred "td" and then the task itself, the taks is shown in todoist with "td" in front of it. in alfred: td buy apples shows in todoist: tdbuy apples How can I fix that? aaand is it possible to change the language of the natural processing languages to something else than english? Link to comment
Stacks Posted June 15, 2023 Author Share Posted June 15, 2023 I'm not sure how you could be getting 'tdbuy apples', as the "td" should be the alfred action. Open a github issue with your debug log and we can take a look. Did you configure "td" as your task_prefix by chance? (you probably want that blank) Todoist NLP is done by Todoist, not me. I have no control over it. According to Todoist, they support several languages, but you would have to reach out to their support to confirm. I believe it works based on what your language setting in your Todoist account is set to. Link to comment
actionjoe Posted June 15, 2023 Share Posted June 15, 2023 I created. a github issue, its super strange what do you mean by task_prefix? where can i see that/ change it? I changed the alfred trigger from td to todo just to see if i get a different result, but no, still td in front of the task... Link to comment
Stacks Posted June 15, 2023 Author Share Posted June 15, 2023 Right/cntrl-click on the workflow, then select "Configure...." And make sure "Task Prefix" is blank I don't see any GitHub issue - where did you open? Link to comment
actionjoe Posted June 15, 2023 Share Posted June 15, 2023 aaah! it works! I didn't add any suffix, but having the suffix part blank sorted the issue thanks a lot! here was the github issue: https://github.com/stacksjb/AlfredTodWorkflow/issues/10 Link to comment
vlar Posted May 21 Share Posted May 21 Just for information, I had to update the zsh script of the work flow to work with the latest Tod version. The arguments changed. export PATH=$PATH:~/.cargo/bin/ if tod t q -c ${task_prefix}${1}${task_suffix} > /dev/null; then echo -n 0 else echo -n 1 fi Link to comment
Stacks Posted May 21 Author Share Posted May 21 Thx for the heads up! That change was already made in the latest version as on Github as of about two weeks ago. I went ahead and submitted for Packal. If anyone is aware of a way to fix update version checking, please let me know. From what I can tell, I can't use the alfred gallary yet because I don't have the homebrew dependencies configured, but I don't have that setup yet and can't find any good documentation on how to configure it. 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