Jump to content


Photo

Reminders


  • Please log in to reply
315 replies to this topic

#1 Jack James

Jack James

    Member

  • Member
  • PipPip
  • 177 posts

Posted 15 March 2013 - 12:43 PM

This workflow lets Alfred create new reminders in reminders.app, and show current reminders*.
 
Basic Usage
 
To use, just type "r reminder_text" into Alfred. E.g. "r check out some of Alfred's other workflows" to find an existing reminder with the search text*, or to create a new one.
Actioning an existing reminder marks it as complete.
 
Advanced Usage
 
Hold option to view the new/existing reminder in Reminders.app, hold control to delete it instead of marking it complete.
 
To set a reminder for a specific date, use any of the following commands:

  • r today release the hamsters into the wild
  • r tomorrow bring about financial ruin upon my enemies
  • r thursday have a banana
  • r in 5 minutes drop everything
  • r in 2 hours laugh out loud in random thoughts list
  • r in 3 days 1 hour pick stuff up off the floor
  • r on 24/12/13 to forget everything I know about things in movies
  • r on 12 June 15 to come up with some interesting ideas
  • r on 11 12 13 to check what the weather's like
  • r on 31-12-99 23:22 to panic about the millennium bug
  • r at 2pm to wait for nothing in particular
  • r thursday at 15.30 to ask some difficult questions

You can use most of the same keywords to show existing reminders, so for example "r tomorrow" will show you all reminders that are due tomorrow, "r in thoughts list" will show you the reminders in the "random thoughts" list, and yes, you can do combinations like "r tomorrow in thoughts list"!
 

Reminders from Applications

You can use "r this" to turn the current application into a reminder, such as the current page in Chrome or Safari, or the current Mail message. Again, combinations are possible, "r this today website to check out in procrastination list" is perfectly feasible!
Currently supported applications: Safari, Google Chrome, Mail, Contacts/Address Book, Finder, Chromium, TextMate, TextEdit, Vienna, OmniFocus, WebKit Nightly, FoldingText, Google Chrome Canary.
 
Please post with requests for other applications and I'll do my best to add support.
 
 

Getting help
Type "r help" to show the above examples in Alfred
 
14plj7.jpg
 

Dates & times

The order of d/m/y (as well as HH:mm) I believe will depend on your region settings in the OS.

The workflow tries to be smart about times, but due to needing to support both 12 and 24-hour clocks, you will get more predictable results when using "at 11am" rather than "at 11:00"
 
2emd0sz.jpg
 
Other keywords

  • "r all" will show all current reminders (as will simply typing "r" with no keywords)*
  • "r refresh" will show all current reminders and refresh the list*
  • "r overdue" will display all overdue reminders*
  • "radd" will show options just for adding reminders
  • "rshow" will only show existing reminders*
  • "rtest" is for debugging purposes and will identify anything that might be broken

If you want to change the default reminder list, edit the applescript property at the top, otherwise it will just use the first one (unless you use "in Y list" at the end).

 

* Not currently supported in OS 10.9

 

Note: OS 10.9 Mavericks / 10.10 Yosemite

 

This workflow currently operates in a "write-only" mode in OS 10.9 or later.

Due to an issue with OS 10.9 (and likely 10.10), I have removed some of the functionality– specifically the ability to view current reminders within Alfred. You can still use all the commands for adding new reminders, and in the event that the issue is fixed, I will restore full functionality. Read on if you want more details on why this is.

 

When using this workflow with 10.9+, performance is extremely slow (14x slower than 10.8) due to an apparent bug in osascript (which may affect other Alfred workflows too, or might just be limited to accessing Reminder data). This means that fetching data from Reminders is taking around a minute or so per reminder. This is a reproducible bug with AppleScript that has nothing to do with Alfred or this workflow, which I have logged with Apple as of October 7 (#15163843), but has not yet been addressed (and as with other bugs, may never be).

 

The workflow is designed to use a caching process to store current reminders (as trying to access them directly on any OS version is somewhat slow), but even this can result in prolonged CPU spikes while the cache is built in 10.9+, as well as general unresponsiveness of Reminders.

 

This is probably the best I can do for now until the bug gets fixed (which might never happen). I am genuinely sorry about this, and if I can figure out a way around it, I will do so, but ultimately the workflow has to communicate with Reminders via AppleScript to some extent.

 

Additional setup for OS 10.9+

 

You will need to enable access to your reminders. You will be prompted to do this when you run the workflow, but if you need to check, go to

System Preferences > Security & Privacy > Privacy > Reminders

Make sure both "Alfred 2" (and "osascript", if it is shown) are enabled.

 
Changelog

  • Saturday, 26 July 2014 – Disable showing reminders in OS 10.10 (Yosemite)

  • Thursday, 9 January 2014 – Fixed Finder links in OS 10.9

  • Saturday, 23 November 2013 – Disable display of existing reminders under OS 10.9

  • Friday, 22 November 2013 – Workflow will now display a message if the command is not valid

  • Saturday, 2 November 2013 – Fixed an issue that would cause the workflow to crash the first few times it was run; fixed an issue that would prevent update checking to work correctly

  • Friday, 1 November 2013 – Fixed an issue where caching reminders would cause update checking to fail

  • Wednesday, 23 October 2013 – Increased timeout on OS 10.9, and allowed reminders to be retrieved from the cache while it's running; times specified without am/pm are now assumed to be in 24hour format; corrected an issue where 12 o'clock times were calculated incorrectly; you can now use "noon" and "midnight" to specify time

  • Tuesday, 22 October 2013 – Prevent cache processes overlapping; recreate damaged cache file if needed; workaround for OS 10.9 GM2 plist bug

  • Wednesday, 9 October 2013 – Added support for Google Chrome Canary; added plain text formats of applescripts; fix for cache process failing for new users

  • Monday, 7 October 2013 – Added profiling to rtest; "r" with no arguments is now the same as "r all"

  • Friday, 4 October 2013 – Compatbility with OS 10.9 Mavericks GM

  • Wednesday, 18 September 2013 – Fix for non-gregorian date format

  • Tuesday, 17 September 2013 – Updated q_workflow module to latest version

  • Wednesday, 10 July 2013 - Added support for OmniFocus 2, TextMate 2 and FoldingText

  • Thursday, 18 April 2013 – Fixed recognition of 10/11/12am/pm times

  • Tuesday, 16 April 2013 -- Added support for WebKit Nightly.
  • Monday, 15 April 2013 – Added "r in x days y hours", "r in x hours y minutes", "r today/tomorrow/weekday at time to x" patterns
  • Thursday, 11 April 2013 – Added support for OmniFocus, Vienna, reminder from address book now adds a link to the contact
  • Wednesday, 10 April 2013 – Fix for -609 error (thanks, stevef!)
  • Tuesday, 9 April 2013 – Added "r refresh" keyword to refresh list ("r all" will no longer refresh the list); added "rshow", which will only show options for existing reminders, "radd", which will only show options for adding new reminders; added "rtest" which runs a set of tests to check for potential problems; fixed an issue that would cause workflow to crash (thanks, erist!)
  • Monday, 8 April 2013 – Better compatibility for editing library scripts on other systems; it's now possible to delete reminders by holding down control; fixed a rare issue where the workflow might incorrectly report a new version is available; iconography tweak; added "overdue" keyword; added support for TextMate and TextEdit; allow "r in 1 minute/hour/day"
  • Sunday, 7 April 2013 – Don't mark reminder as complete with option held down; properly escape illegal characters in query; added support for Finder and Chromium
  • Saturday, 6 April 2013 – Added "r this" which captures data from the current application and turns it into a reminder; support for Google Chrome, Safari, and Mail; fixed a regression; support for contacts/address book; added icons from the icon factory; "r all" now refreshes the cache
  • Friday, 5 April 2013 – Show "r all" in help; don't close reminders if its been moved to the foreground; all keywords can now be used to filter displayed reminders; changed the cache duration to 2 hours; subtitle for existing reminders shows more information where possible
  • Thursday, 4 April 2013 – Performance improvements; hold option to view the selected reminder in Reminders.app
  • Wednesday, 3 April 2013 – Fix for "in list" pattern breaking up text; added "r help" examples; don't prompt to create reminder with "all" keyword; checks for newer versions of the workflow
  • Tuesday, 2 April 2013 – If reminders.app is closed, it will stay closed when using this workflow
  • Sunday, 31 March 2013 – Added pattern "r Wednesday something"
  • Wednesday, 27 March 2013 – Renamed workflow to "Reminders"; Use application id instead of name, Alfred now shows existing reminders in his list (selecting one will mark it as complete); keyword is now optional
  • Tuesday, 26 March 2013 – Now sets specified date as the reminder date, rather than due date; added pattern "r something in Y list"
  • Wednesday, 20 March 2013 – You can now use the pattern "r at 1.30 to something"; Alfred will tell you what's going to happen before you press enter; split off code to library file
  • Tuesday, 19 March 2013 – You can now use the pattern "r in X minutes/hours/days something"
  • Sunday, 17 March 2013 – You can now specify a date for the reminder. See the examples above.

Download
http://bit.ly/10uCE2J (Approx. 1MB)
 
Note: this workflow will notify you if a newer version is available. To disable this functionality, change the property "shouldCheckForUpdates" to "false"

 

Source: https://github.com/s...lfred-reminders
 
Disclaimer
This workflow is provided as-is, use it at your own risk. I can't take any responsibility for anything bad that happens as a result of using it, including, but not limited to, loss of data, loss of sanity, spontaneous human combustion.

 

Feedback

By far the best way to give me feedback is to submit an issue on GitHub. Alternatively, just reply to this post.


Edited by Jack James, 26 July 2014 - 06:13 PM.

  • twinpeaks, drking, JorjGaidin and 11 others like this

#2 Davduf

Davduf

    Newbie

  • Member
  • Pip
  • 15 posts

Posted 15 March 2013 - 08:11 PM

It works!

Thank you !

 

Do you think we could add automatically the date of the day ? That could be very useful.

Thx !


  • kashifnoorani likes this

#3 MikeBox

MikeBox

    Newbie

  • Member
  • Pip
  • 4 posts

Posted 15 March 2013 - 08:49 PM

Great thank you!



#4 jayelevy

jayelevy

    Newbie

  • Member
  • Pip
  • 1 posts

Posted 15 March 2013 - 09:32 PM

It works!

Thank you !

 

Do you think we could add automatically the date of the day ? That could be very useful.

Thx !

 

Simply change the script as follows:

 

current: make new reminder with properties {name:q}

 

new: make new reminder with properties {name:q, due date:(current date)}



#5 Davduf

Davduf

    Newbie

  • Member
  • Pip
  • 15 posts

Posted 15 March 2013 - 09:50 PM

Perfect !

 

Simply change the script as follows:

 

current: make new reminder with properties {name:q}

 

new: make new reminder with properties {name:q, due date:(current date)}



#6 bocaboy

bocaboy

    Member

  • Member
  • PipPip
  • 21 posts
  • LocationBoca Raton, FL

Posted 15 March 2013 - 10:39 PM

I would love to use this method for creating a new note in Notes. I tried changing "reminder" to "notes" but didn't get it to work. Here's how it looks:

 

 

on alfred_script(q)
  tell application "Notes"
make new note with properties {name:q}
end tell
return {q}
end alfred_script
 
Can anyone tell me what needs to be changed?? Many thanks!


#7 Jack James

Jack James

    Member

  • Member
  • PipPip
  • 177 posts

Posted 16 March 2013 - 10:29 AM

I would love to use this method for creating a new note in Notes. I tried changing "reminder" to "notes" but didn't get it to work. Here's how it looks:

 

 

on alfred_script(q)
  tell application "Notes"
make new note with properties {name:q}
end tell
return {q}
end alfred_script
 
Can anyone tell me what needs to be changed?? Many thanks!

Quick & dirty:

 

on alfred_script(q)
    tell application "Notes"
        tell first account
            make new note at folder "Notes" with properties {name:q, body:q}
        end tell
    end tell
end alfred_script
 

 

created a workflow: http://www.alfredfor...9-add-new-note/


Edited by surrealroad, 16 March 2013 - 10:53 AM.

  • Hozman likes this

#8 bocaboy

bocaboy

    Member

  • Member
  • PipPip
  • 21 posts
  • LocationBoca Raton, FL

Posted 16 March 2013 - 03:10 PM

Subsequent to my post under this string, I found your other workflow for Notes and it's working perfectly. I use Notes extensively, so that workflow is a godsend to me!



#9 thinkfilm

thinkfilm

    Newbie

  • Member
  • Pip
  • 7 posts

Posted 16 March 2013 - 03:43 PM

Workflow works great for me.  However I have two (2) Lists in Reminders -- one is "Calendar" located On My Mac and the other is "Reminders" located on iCloud.  Is it possible to select which List the reminder that this workflow creates goes to?  I'm sure it's a change in the Applescript but I'm stumped.

 

Thanks.



#10 Jack James

Jack James

    Member

  • Member
  • PipPip
  • 177 posts

Posted 17 March 2013 - 09:43 AM

Workflow works great for me.  However I have two (2) Lists in Reminders -- one is "Calendar" located On My Mac and the other is "Reminders" located on iCloud.  Is it possible to select which List the reminder that this workflow creates goes to?  I'm sure it's a change in the Applescript but I'm stumped.

 

Thanks.

I didn't consider that possibility! Download the updated version in the original post, and you can set the name of the list to use at the top of the applescript


  • Hozman likes this

#11 Jack James

Jack James

    Member

  • Member
  • PipPip
  • 177 posts

Posted 17 March 2013 - 01:16 PM

It works!

Thank you !

 

Do you think we could add automatically the date of the day ? That could be very useful.

Thx !

See the newest version



#12 thinkfilm

thinkfilm

    Newbie

  • Member
  • Pip
  • 7 posts

Posted 17 March 2013 - 02:44 PM

I didn't consider that possibility! Download the updated version in the original post, and you can set the name of the list to use at the top of the applescript

That was fast.  Thanks for the revision and the info.  Much appreciated.


Edited by thinkfilm, 17 March 2013 - 02:45 PM.


#13 ravexave

ravexave

    Newbie

  • Member
  • Pip
  • 3 posts

Posted 17 March 2013 - 04:03 PM

Great workflow, but would have been nice to set a alarm time as well. Anybody know how to modify the script?



#14 Jack James

Jack James

    Member

  • Member
  • PipPip
  • 177 posts

Posted 17 March 2013 - 06:31 PM

Great workflow, but would have been nice to set a alarm time as well. Anybody know how to modify the script?

modify it to do what exactly? 

 

Are you using the lastest version with the ability to set the date as per the description?



#15 ravexave

ravexave

    Newbie

  • Member
  • Pip
  • 3 posts

Posted 17 March 2013 - 08:19 PM

modify it to do what exactly? 

 

Are you using the lastest version with the ability to set the date as per the description?

 

Yes, I am using the latest version. However, I am not talking exclusively about the date. I just wondered if it´s possible to set a reminder for a date AND the time for the reminder, for instance 18/03/13 at 1800 hours or 6 pm.



#16 Jack James

Jack James

    Member

  • Member
  • PipPip
  • 177 posts

Posted 17 March 2013 - 08:43 PM

you can, just put the time immediately after the date. I'll update the example



#17 ravexave

ravexave

    Newbie

  • Member
  • Pip
  • 3 posts

Posted 17 March 2013 - 09:06 PM

Amazing! Thanks!



#18 Leech

Leech

    Member

  • Member
  • PipPip
  • 29 posts

Posted 17 March 2013 - 10:11 PM

Thank you, it works really nice.



#19 dasmart

dasmart

    Newbie

  • Member
  • Pip
  • 1 posts

Posted 19 March 2013 - 02:29 AM

Thank you! This is a great workflow. I find that I use reminders for short term tasks, so for me the examples below would be a huge help.

 

r 10 minutes release the hamsters into the wild

r in 3 hours release the hamsters into the wild

 



#20 Jack James

Jack James

    Member

  • Member
  • PipPip
  • 177 posts

Posted 19 March 2013 - 11:06 AM

Thank you! This is a great workflow. I find that I use reminders for short term tasks, so for me the examples below would be a huge help.

 

r 10 minutes release the hamsters into the wild

r in 3 hours release the hamsters into the wild

 

Good idea! See the latest version.




2 user(s) are reading this topic

0 members, 2 guests, 0 anonymous users