Pinuz Posted November 25, 2020 Posted November 25, 2020 (edited) This readme could be outdated. Here there's the updated one. Create new tasks, mark tasks complete, and track the hours spent on each task. Installation 1. Download the latest release of the workflow. 2. Double click to add it to Alfred. 3. Run any command and follow the instructions for the setup. Reports If you want to generate reports of what you have done, you need to install QLMarkdown, a QuickLook plugin to preview Markdown files. To install it, open a terminal and run the following command brew cask install qlmarkdown Usage Commands asn create — Create a new Asana task asn complete — Mark an Asana task complete asn start — Start the timer for an Asana task asn stop — Stop the timer for an Asana task asn cancel — Cancel the timer of an Asana task asn reset — Reset Alfred's knowledge on an Asana task asn report — Show a report of what you have done. You can specify a time frame asn set token — Set your Personal Access Token asn set workspace — Set your default workspace asn set project — Set your default project New tasks are created on your default project. When you start a task, you'll be asked to select the field where you want to track the spent hours. Please note that when you stop or complete the task, this field will be overwritten by Alfred. When you reset a task, the history that generates the reports won't be affected. Examples asn create feed the hamster asn complete learn ballade no. 1 in g minor asn start prove p=np asn stop find the x asn set project conquer the world asn report week asn report 8 hours asn report 2 days GitHub Edited December 3, 2020 by Pinuz
Pinuz Posted December 3, 2020 Author Posted December 3, 2020 I've updated the workflow. You should get an automatic update. Changelog Features Show recently used items first In the report, aggregate small tasks in "Other"
mashby Posted January 5, 2021 Posted January 5, 2021 I am having no luck getting the token set. I type "asn set token" and then copy-and-paste the token, which starts "1/1431..." and then hit enter. No errors or alerts are reported. But when I enter "ask create..." I'm shown that I need to set the token, which I've already done. I have tried this a couple of times and had no luck. any help you could provide would be most appreciated.
Pinuz Posted January 5, 2021 Author Posted January 5, 2021 Can you copy paste here the log from the `asn set token` to the `asn create`? To see the log open the workflow on Alfred and click on the bug on the top right corner. Before sending the reply please remove your real token
mashby Posted January 5, 2021 Posted January 5, 2021 (edited) Thank you for the fast reply, BTW! [13:26:57.555] Asana Tracker[Script Filter] Queuing argument '(null)' [13:26:57.834] Asana Tracker[Script Filter] Script with argv '(null)' finished [13:26:57.835] STDERR: Asana Tracker[Script Filter] . 13:26:57 workflow.py:2061 DEBUG ---------- Asana Tracker (0.3.0) ---------- 13:26:57 workflow.py:1468 DEBUG reading settings from /Users/mashby/Library/Application Support/Alfred/Workflow Data/it.ggallo.asana/settings.json 13:26:57 workflow.py:2254 DEBUG set last run version: 0.3.0 13:26:57 workflow.py:2103 DEBUG ---------- finished in 0.046s ---------- [13:26:57.835] Asana Tracker[Script Filter] { "items": [ { "arg": "%get_token", "valid": true, "subtitle": "Click to open the browser", "title": "Get your Personal Access Token from Asana" }, { "arg": "%set_token", "valid": true, "subtitle": "Click to set your Personal Access Token", "title": "Set your Personal Access Token" } ] } [13:27:02.170] Asana Tracker[Script Filter] Processing complete [13:27:02.173] Asana Tracker[Script Filter] Passing output '%set_token' to Conditional [13:27:02.174] Asana Tracker[Conditional] Processing complete [13:27:02.174] Asana Tracker[Conditional] Passing output '%set_token' to Replace [13:27:02.175] Asana Tracker[Replace] Processing complete [13:27:02.175] Asana Tracker[Replace] Passing output '' to Keyword [13:27:05.041] Asana Tracker[Keyword] Processing complete [13:27:05.045] Asana Tracker[Keyword] Passing output '1/143...' to Run Script [13:28:32.675] Asana Tracker[Script Filter] Queuing argument 'T' [13:28:32.837] Asana Tracker[Script Filter] Queuing argument 'Te' [13:28:32.992] Asana Tracker[Script Filter] Queuing argument 'Tes' [13:28:33.054] Asana Tracker[Script Filter] Queuing argument 'Test' [13:28:33.140] Asana Tracker[Script Filter] Queuing argument 'Testi' [13:28:33.208] Asana Tracker[Script Filter] Queuing argument 'Testin' [13:28:33.392] Asana Tracker[Script Filter] Script with argv '(null)' finished [13:28:33.392] STDERR: Asana Tracker[Script Filter] . 13:28:33 workflow.py:2061 DEBUG ---------- Asana Tracker (0.3.0) ---------- 13:28:33 workflow.py:1468 DEBUG reading settings from /Users/mashby/Library/Application Support/Alfred/Workflow Data/it.ggallo.asana/settings.json 13:28:33 workflow.py:2254 DEBUG set last run version: 0.3.0 13:28:33 workflow.py:2103 DEBUG ---------- finished in 0.037s ---------- [13:28:33.399] Asana Tracker[Script Filter] { "items": [ { "arg": "%set_token", "valid": true, "subtitle": "Click to set your Personal Access Token", "title": "Not authenticated" } ] } [13:28:34.013] Asana Tracker[Script Filter] Queuing argument 'Testing' [13:28:34.244] Asana Tracker[Script Filter] Script with argv '(null)' finished [13:28:34.245] STDERR: Asana Tracker[Script Filter] . 13:28:34 workflow.py:2061 DEBUG ---------- Asana Tracker (0.3.0) ---------- 13:28:34 workflow.py:1468 DEBUG reading settings from /Users/mashby/Library/Application Support/Alfred/Workflow Data/it.ggallo.asana/settings.json 13:28:34 workflow.py:2254 DEBUG set last run version: 0.3.0 13:28:34 workflow.py:2103 DEBUG ---------- finished in 0.026s ---------- [13:28:34.256] Asana Tracker[Script Filter] { "items": [ { "arg": "%set_token", "valid": true, "subtitle": "Click to set your Personal Access Token", "title": "Not authenticated" } ] } [13:28:34.405] Asana Tracker[Script Filter] Queuing argument 'Testing ' [13:28:34.631] Asana Tracker[Script Filter] Queuing argument 'Testing 1' [13:28:34.645] Asana Tracker[Script Filter] Script with argv '(null)' finished [13:28:34.646] STDERR: Asana Tracker[Script Filter] . 13:28:34 workflow.py:2061 DEBUG ---------- Asana Tracker (0.3.0) ---------- 13:28:34 workflow.py:1468 DEBUG reading settings from /Users/mashby/Library/Application Support/Alfred/Workflow Data/it.ggallo.asana/settings.json 13:28:34 workflow.py:2254 DEBUG set last run version: 0.3.0 13:28:34 workflow.py:2103 DEBUG ---------- finished in 0.026s ---------- [13:28:34.647] Asana Tracker[Script Filter] { "items": [ { "arg": "%set_token", "valid": true, "subtitle": "Click to set your Personal Access Token", "title": "Not authenticated" } ] } [13:28:34.800] Asana Tracker[Script Filter] Queuing argument 'Testing 1 ' [13:28:34.864] Asana Tracker[Script Filter] Script with argv '(null)' finished [13:28:34.865] STDERR: Asana Tracker[Script Filter] . 13:28:34 workflow.py:2061 DEBUG ---------- Asana Tracker (0.3.0) ---------- 13:28:34 workflow.py:1468 DEBUG reading settings from /Users/mashby/Library/Application Support/Alfred/Workflow Data/it.ggallo.asana/settings.json 13:28:34 workflow.py:2254 DEBUG set last run version: 0.3.0 13:28:34 workflow.py:2103 DEBUG ---------- finished in 0.027s ---------- [13:28:34.881] Asana Tracker[Script Filter] { "items": [ { "arg": "%set_token", "valid": true, "subtitle": "Click to set your Personal Access Token", "title": "Not authenticated" } ] } [13:28:35.006] Asana Tracker[Script Filter] Queuing argument 'Testing 1 2' [13:28:35.147] Asana Tracker[Script Filter] Queuing argument 'Testing 1 2 ' [13:28:35.377] Asana Tracker[Script Filter] Script with argv '(null)' finished [13:28:35.378] STDERR: Asana Tracker[Script Filter] . 13:28:35 workflow.py:2061 DEBUG ---------- Asana Tracker (0.3.0) ---------- 13:28:35 workflow.py:1468 DEBUG reading settings from /Users/mashby/Library/Application Support/Alfred/Workflow Data/it.ggallo.asana/settings.json 13:28:35 workflow.py:2254 DEBUG set last run version: 0.3.0 13:28:35 workflow.py:2103 DEBUG ---------- finished in 0.026s ---------- [13:28:35.395] Asana Tracker[Script Filter] { "items": [ { "arg": "%set_token", "valid": true, "subtitle": "Click to set your Personal Access Token", "title": "Not authenticated" } ] } [13:28:35.407] Asana Tracker[Script Filter] Queuing argument 'Testing 1 2 3' [13:28:35.636] Asana Tracker[Script Filter] Script with argv '(null)' finished [13:28:35.637] STDERR: Asana Tracker[Script Filter] . 13:28:35 workflow.py:2061 DEBUG ---------- Asana Tracker (0.3.0) ---------- 13:28:35 workflow.py:1468 DEBUG reading settings from /Users/mashby/Library/Application Support/Alfred/Workflow Data/it.ggallo.asana/settings.json 13:28:35 workflow.py:2254 DEBUG set last run version: 0.3.0 13:28:35 workflow.py:2103 DEBUG ---------- finished in 0.026s ---------- [13:28:35.656] Asana Tracker[Script Filter] { "items": [ { "arg": "%set_token", "valid": true, "subtitle": "Click to set your Personal Access Token", "title": "Not authenticated" } ] } [13:28:38.153] Asana Tracker[Script Filter] Processing complete [13:28:38.153] Asana Tracker[Script Filter] Passing output '%set_token' to Conditional [13:28:38.154] Asana Tracker[Conditional] Processing complete [13:28:38.154] Asana Tracker[Conditional] Passing output '%set_token' to Replace [13:28:38.155] Asana Tracker[Replace] Processing complete [13:28:38.155] Asana Tracker[Replace] Passing output '' to Script Filter [13:28:38.205] Asana Tracker[Script Filter] Queuing argument '(null)' [13:28:38.357] Asana Tracker[Script Filter] Script with argv '(null)' finished [13:28:38.358] STDERR: Asana Tracker[Script Filter] . 13:28:38 workflow.py:2061 DEBUG ---------- Asana Tracker (0.3.0) ---------- 13:28:38 workflow.py:1468 DEBUG reading settings from /Users/mashby/Library/Application Support/Alfred/Workflow Data/it.ggallo.asana/settings.json 13:28:38 workflow.py:2254 DEBUG set last run version: 0.3.0 13:28:38 workflow.py:2103 DEBUG ---------- finished in 0.022s ---------- [13:28:38.380] Asana Tracker[Script Filter] { "items": [ { "arg": "%get_token", "valid": true, "subtitle": "Click to open the browser", "title": "Get your Personal Access Token from Asana" }, { "arg": "%set_token", "valid": true, "subtitle": "Click to set your Personal Access Token", "title": "Set your Personal Access Token" } ] } Edited January 5, 2021 by mashby
Pinuz Posted January 6, 2021 Author Posted January 6, 2021 That's very weird 🤔 After that you enter the token you should receive either 'Authentication succeeded! Enjoy the workflow' or 'Authentication failed! Check your token and your internet connection'. Could it be that your connection is very slow and the request fails in some unexpected way? Have you tried to wait a bit more before creating a new task?
mikejandreau Posted April 14, 2021 Posted April 14, 2021 Thanks for this workflow, it's incredible! One item I'd love to add, but don't know how: When I "Complete" a task, I don't want to mark it as complete in Asana (since it needs to go to review). Instead, I need to change the value of a custom field on the Task to something else (which is always the same). So, example: Custom Status: In Progress → Mark "Complete" in Workflow → Set Custom Status on Task to "In Review" (someone else actually marks it as Done in Asana. If you could help me with this, I'd be externally grateful.
mikejandreau Posted April 14, 2021 Posted April 14, 2021 Figured it out. I had to define my own whatever-python-calls-what-i-would-call-a-function for `in_review`, then call it in its own Python Script.
mikejandreau Posted April 14, 2021 Posted April 14, 2021 A request for a future update: ability to add a comment to a task and the ability to assign a task to a user (as well as assign the task to another board).
Katrinall Posted April 17, 2021 Posted April 17, 2021 (edited) On 4/15/2021 at 1:59 AM, mikejandreau said: Figured it out. I had to define my own whatever-python-truecallera mod apk-what-i-would-call-a-function for `in_review`, then call it in its own Python Script. Can you share more clearly what you find out? Edited April 19, 2021 by Katrinall
Pinuz Posted April 17, 2021 Author Posted April 17, 2021 On 4/14/2021 at 8:59 PM, mikejandreau said: Figured it out. I had to define my own whatever-python-calls-what-i-would-call-a-function for `in_review`, then call it in its own Python Script. Great! Have you used the `set_field_value` function defined in api.py? On 4/14/2021 at 10:17 PM, mikejandreau said: A request for a future update: ability to add a comment to a task and the ability to assign a task to a user (as well as assign the task to another board). I'd like to implement the "set field/assignee/projects" feature as well, but I haven't yet found the time to do it 😅
mikejandreau Posted April 21, 2021 Posted April 21, 2021 On 4/17/2021 at 4:52 AM, Pinuz said: Great! Have you used the `set_field_value` function defined in api.py? I didn't use it, because I couldn't figure out how to call it in the Workflow to see what it did. But I essentially did what I'd assume it would do based on its name, but hard-coded my field name into the API call.
mimi sen Posted August 10, 2021 Posted August 10, 2021 On 4/17/2021 at 2:03 PM, Katrinall said: On 4/15/2021 at 12:29 AM, mikejandreau said: I had to define my own whatever-python-truecallera mod apk-what-i-would-call-a-function for `in_review`, then call it in its own Python Script. Thank you for your help it was pretty helpful for me.
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