Created
February 25, 2012 17:17
-
-
Save yoko/1909587 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on run {input, parameters} | |
if length of input ≤ 1 then | |
try | |
do shell script "/usr/local/bin/growlnotify -a Evernote -t \"Clip Images\" -m \"Image not found\"" | |
end try | |
return | |
end if | |
tell application "Evernote" | |
if (not (notebook named "Inbox" exists)) then | |
make notebook with properties {name:"Inbox"} | |
end if | |
set aTitle to do shell script "date \"+%Y-%m-%d %H:%M\"" | |
set images to items 1 thru -2 of input | |
set aSourceURL to last item of input | |
set aNote to create note title aTitle with text "" attachments images notebook "Inbox" | |
tell aNote to set source URL to aSourceURL | |
end tell | |
try | |
do shell script "/usr/local/bin/growlnotify -a Evernote -t \"Clip Images\" -m \"Completed\"" | |
end try | |
end run |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment