Find me on...
LinkedInPersonal TwitterPersonal Google+SAP TwitterROC Google+QuoraXingKloutSAP Community Network

Search

« A Quick Fix for Swype Users | Main | PDF Quick Save in Word 2007 »
Friday
Jul082011

Search Evernote from Alfred (again...)


About a month ago I wrote a script (and a blog post) to allow me to search Evernote direct from the Alfred app on my Mac. Today Andrew Pepperrell (the developer of Alfred) released a developer build with some nice new features and one of these makes the process of setting up my little search even simpler!

EDIT: The beta testing is over and this is now a standard Alfred feature


So at the time of writing, this new version of Alfred really is hot off the keyboard. It may be by the time you're reading this post that the new features are on general release, but if not I grabbed my copy of Alfred 0.9.9 dev 1 build from the dev download page. The feature you're going to need available is that of importing an extension.



The packaged up version of my search Evernote script is available to download using the link below. Save the zip file to a convenient location then open up Alfred's preferences. Navigate to the "Extensions" settings and simply drag and drop the zip file onto the window. On the new pop-up just click the "Import" button and you'll now be looking at the Search Evernote extension.



Rather than running via osascript from the terminal, Alfred now allows AppleScript to be called directly. The script is almost identical to that posted previously, but now fits to the couple of lines of AppleScript Alfred uses to pass the query parameters in.



For more on how it all works go back and check out my previous post, but the real beauty is you can just import with a drag and drop and you're ready to search.


PrintView Printer Friendly Version

EmailEmail Article to Friend

Reader Comments (10)

Big thanks for the script! I love it so much I made my own version which always executes the searches in the same window, and putting Evernote up front after the search. Read about it and download the extension here: http://tumblr.com/xt945g59t1

Great work! /Pontus

August 17, 2011 | Unregistered CommenterPontus Sundén

Have to say that we are living in wonderful times. Thanks for the help, the greatly improved installation procedure (thanks Andrew) and the refined extension (Pontus).

Drinks all round.

r

August 17, 2011 | Unregistered CommenterRichard Levenson

Cheers! ;)

August 18, 2011 | Unregistered CommenterPontus Sundén

This works great! Many thanks!

December 6, 2011 | Unregistered CommenterJas

sorry if I am being thick (I am new to both Alfred and Evernote) but what sort of advantage does that give you compared to using the global "Evernote Search" shortcut (which works whether the Evernote app is running or not)?

December 14, 2011 | Unregistered Commenterjez foreg

Jez.

I'm not sure what global Evernote search you're referring to, but I'll see if I can cover off a few possibilities.

When Evernote is running CTRL+CMD+E opens the Evernote app for a search. This isn't available is Evernote isn't running (not for me at least).

CMD+SPACE opens spotlight search which can search Evernote , but you can't use any advanced search syntax specific to Evernote (e.g. tags and notebooks).

Using Alfred you can trigger the search even when Evernote is closed and make use of the advanced search syntax. You also get the approach that Alfred becomes your central start point for yet another action. Centralising just gives familiarity and you might have to remember fewer hot keys, but the downside is you might have to remember another special term (the one to trigger the Evernote search) - I personally think it just balances out.

Does that cover it? I'm sure others can probably add a few advantages for triggering the search from Alfred.If I've missed the mark let me know what you mean and I'll have a second pass.

December 14, 2011 | Registered CommenterStephen Millard

Cheers for the extension, works great! :) Am quite new to both Alfred and AppleScript, so well impressed with your work so far.

Thanks again!

January 8, 2012 | Unregistered CommenterGleb Reys

The drag and drop functionality is great, but it should be noted that Extensions requires the user to buy the Powerpack feature. Free users are unable to drop it in like that.

Rich

January 16, 2012 | Unregistered CommenterRich Duprey

Your extension uses applescript as i commented in your other post. Same problem here: each search word gets surrounded by its own quotes.

March 2, 2012 | Unregistered CommenterRobert

Hi Robert.

I've done a quick bit of testing...

Enter into Alfred: $en "term1 term2"
Resulting search in Evernote: "term1 term2"

Enter into Alfred: $en term1 term2
Resulting search in Evernote: "term1" "term2"

I then did a direct bit of AppleScript (outside of Alfred):

tell Application "Evernote"
open collection window with query string "term1 term2"
end tell

This again resulted in: "term1" "term2"

So I guess that the AppleScript interface to Evernote is adding in the additional double quotation marks.

So I tried a couple of quick comparisons between the search results for:
term1 term2
vs.
"term1" "term2"
I got identical results sets back each time I varied the search terms.

Can you provide some details around when theses two search strings produce differing results?

March 3, 2012 | Registered CommenterStephen Millard

PostPost a New Comment

Enter your information below to add a new comment.
Author Email (optional):
Author URL (optional):
Post:
 
Some HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>