Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@wwwjfy
Created October 7, 2015 08:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wwwjfy/f3255801888a5cf01829 to your computer and use it in GitHub Desktop.
Save wwwjfy/f3255801888a5cf01829 to your computer and use it in GitHub Desktop.
Convert Evernote notes to Notes notes
tell application "Evernote"
set foundNotes to find notes
repeat with aNote in foundNotes
set enTitle to (the title of aNote)
set aHTML to HTML content of aNote
if exists (source URL of aNote) then
set aHTML to "<p>source url: " & source URL of aNote & "</p>" & aHTML
end if
set folderName to (name of notebook of aNote)
tell application "Notes"
tell account [0]
if not (exists folder folderName) then
make new folder with properties {name:folderName}
end if
if not (exists note enTitle in folder folderName) then
make new note at folder folderName with properties {name:enTitle, body:aHTML}
end if
end tell
end tell
end repeat
end tell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment