Closed nikitavoloboev closed 7 years ago
Yeah, an extra action would be indeed really nice. I just want to bind a hotkey to an action of viewing my report for 'this week' as that is the only repot I look at and I want to skip the steps of getting to it every time though the menu.
Thank you.
Also I have a question, does the week report range from Monday to Sunday? Or perhaps some other date?
It's just that I tried running the report this sunday and it showed no results and I found it quite strange.
Having action going directly to 'reports' would work too for me. As I can easily go to the correct time period after. Can this be already done perhaps?
I added support for this in 2.1.0. The support is in 2 parts:
Give that a try.
Also I have a question, does the week report range from Monday to Sunday? Or perhaps some other date?
It should be Sunday - Saturday (it's based on Go's day numbering). I have a TODO item in there about making the work week configurable.
Ok, I downloaded it but it seems to not work at all now. I mean I logged in correctly but now when the menu shows up :
Pressing enter on any of the fields does nothing.
Hmmm... If you open the workflow in Alfred's preferences and open the debug log, do any errors show up when you try to action one of the menu items? Does tgp
work? (It's basically the same as selecting 'projects' and hitting enter.)
Yeah, you are right. Here are the logs I get for errors :
And in text :
Starting debug for 'toggl'
[2016-10-12 00:06:33][STDERR: input.scriptfilter] [alfred] 2016/10/12 00:06:33 Alfred version: 3.1.1
[toggl] 2016/10/12 00:06:33 Using config file: /Users/nikivi/Library/Application Support/Alfred 3/Workflow Data/com.jason0x43.alfred-toggl/config.json
[toggl] 2016/10/12 00:06:33 Using cache file: /Users/nikivi/Library/Caches/com.runningwithcrayons.Alfred-3/Workflow Data/com.jason0x43.alfred-toggl/cache.json
[toggl] 2016/10/12 00:06:33 Error loading config: open /Users/nikivi/Library/Caches/com.runningwithcrayons.Alfred-3/Workflow Data/com.jason0x43.alfred-toggl/cache.json: no such file or directory
[alfred] 2016/10/12 00:06:33 set keyword to ''
[alfred] 2016/10/12 00:06:33 tell: data=alfred.workflowData{Keyword:"", Mode:"tell", Mod:"", Data:""}, arg=''
[alfred] 2016/10/12 00:06:33 Adding menu item for 'status'
[alfred] 2016/10/12 00:06:33 Skipping disabled command 'login'
[alfred] 2016/10/12 00:06:33 Skipping disabled command 'token'
[alfred] 2016/10/12 00:06:33 Adding menu item for 'timers'
[alfred] 2016/10/12 00:06:33 Adding menu item for 'projects'
[alfred] 2016/10/12 00:06:33 Adding menu item for 'tag'
[alfred] 2016/10/12 00:06:33 Adding menu item for 'report'
[alfred] 2016/10/12 00:06:33 Adding menu item for 'options'
[alfred] 2016/10/12 00:06:33 Adding menu item for 'logout'
[alfred] 2016/10/12 00:06:33 Adding menu item for 'reset'
[alfred] 2016/10/12 00:06:33 Fuzzy sorting items
[2016-10-12 00:06:34][ERROR: action.script] [alfred] 2016/10/12 00:06:34 Alfred version: 3.1.1
[toggl] 2016/10/12 00:06:34 Using config file: /Users/nikivi/Library/Application Support/Alfred 3/Workflow Data/com.jason0x43.alfred-toggl/config.json
[toggl] 2016/10/12 00:06:34 Using cache file: /Users/nikivi/Library/Caches/com.runningwithcrayons.Alfred-3/Workflow Data/com.jason0x43.alfred-toggl/cache.json
[toggl] 2016/10/12 00:06:34 Error loading config: open /Users/nikivi/Library/Caches/com.runningwithcrayons.Alfred-3/Workflow Data/com.jason0x43.alfred-toggl/cache.json: no such file or directory
Hmmm...errors for missing files aren't necessarily problematic, and if it's showing you the main menu, then it's loading the config properly. (That "Error loading config" message is actually for the cache file.) I'd expect you to have a cache file, though.
Does the directory /Users/nikivi/Library/Caches/com.runningwithcrayons.Alfred-3/Workflow Data/com.jason0x43.alfred-toggle
exist?
It exists but it is empty.
Still have the issue of all options being unclickable, should I just try and reinstall the workflow?
Sorry about the delay; just got back from vacation. :) Anyway, you could try that. It's not clear from the debug log exactly what's wrong. You've logged in successfully and the config file has been created, because it's showing you the logged-in menu items.
Another thing would be to try actioning the "status" item and see if a cache is created. That will download your time entries from Toggl. It should be doing that by default when you don't have any cached data, but maybe there's an issue there.
Hey Jason,
It is working now. :)
I especially love how report is on the top of the list now. It is extremely handy for me.
Great, glad to hear it's working!
Hmmm...it would definitely involve an extra action in the workflow, and currently an action couldn't directly trigger a weekly report (well, not without some extra scripting). I could rework where the date span calculation happens, which would make this pretty straightforward.