-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Things Extension #85
Conversation
What time zone are the scripts working in? It appears that for tasks due today, it gives the time of midnight of the day before. I am not sure if this is the intended behavior. For example, if a task is due today and it's 6 am, the today script says due 6 hrs ago. It could perhaps be more beneficial to just say today or perhaps could to the next day's midnight, so instead of due 6 hrs ago, it would say due in 16 hrs if that makes sense. |
@Daniel-Joseph great feedback, indeed I was planning to do something like this. I stumbled upon a Things workflow for Alfred and the author is doing something similar to what you suggested (ie, displaying "today"), here: https://github.com/xilopaint/alfred-things/blob/master/src/things.applescript#L96 |
@Daniel-Joseph added a new |
Oh wow that's a really nice and quick fix. I think I just found another unintended bug. For recurring tasks in upcoming, the date before this last commit would say in 17000 days, and now after your most recent changes says Jan 1 even if the recurring task is set to be due this week. I do not personally know how to address this. |
@Daniel-Joseph interesting, it looks like a really strange bug (or maybe on purpose), but the dueDate for a recurring task with deadlines is indeed "Mon Jan 01 4001 00:00:00 GMT+0100" when using Apple Script I guess, Things is storing recurring deadlines in another structure I am not aware of (or, I'm afraid, is not available through Script). I'll keep looking. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @loris, thanks for your contribution! This is really impressive, I didn't realise that it's possible to build such extension with Things, I thought they are pretty limited when it comes to API.
Few minor things to improve:
- Let's add an icon for "Mark as Completed" action, otherwise it looks a bit off. There is
Icon.Checkmark
that would probably fit well.
- I noticed that when I run "Mark as Completed" with one of my items, it didn't disappear from the list or gave any indication that it was successful. Do you think we could show a toast and also delete the item from the list? Or maybe change icon to checkmark and then delete after short delay to make it even nicer. What do you think?
Hi @PitNikola, thanks for the review! Do you think we can release the first version (which is read-only) as it is right now so that I can start getting feedbacks? (For instance, I planned to add a "Create To-Do" form, but I'm not even sure this will be useful since Things has a powerful "Quick entry" form that can be invoked with global shortcut) Thanks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, got it! Yeah, I was running in Dev env. Ok, then it's fine, we can ship it like this and see.
* Add Things Extension * Add caching for faster display of lists * Improve display of dueDate * Fix formatDueDate pluralization
Description
Here is the first working version of a Things extension. It currently uses JXA (ie, AppleScript using JavaScript) to communicate with Things, so Things needs to be installed and running.
It is very basic at the moment: it includes several commands to list the To-Dos from Things lists (Inbox, Today, etc) and allows to filter and open to-dos.
Expect several improvements and new features in the coming days (have a look at the screenshot for some hints).
Feel free to test, give me feedbacks or contribute.
Type of change
Screencast
Checklist