Live data from Hacker News

Show HN: Apple Notes Liberator – Extract Notes.app Data and Save It as JSON

github.com

21–30 of 107 posts

Re: Show HN: Apple Notes Liberator – Extract Notes.app Data and Save It as JSON

#21
Here's a Python script that takes the JSON output from https://github.com/threeplanetssoftware/apple_cloud_notes_pa... (needs master), and rebuilds Notes in Markdown format (or HTML), with links, attachments, lists, etc.:

https://gist.github.com/vszakats/5a3bd939721d1dde6142d9ea3b2...

And a short, standalone JXA script, that outputs HTML, but loses some data, such as links: https://gist.github.com/vszakats/f24e7700428c1e694e20cee0b1c...

Re: Show HN: Apple Notes Liberator – Extract Notes.app Data and Save It as JSON

#22
Oh neat. I’ve been using Notes extensively since the beginning of this year. Daily journaling. Personal TODO lists, grocery list (shared w my wife), and gym/workout tracking.

It works really well and has way more features than people realize. If you’re looking for like a “Notion-lite”, the answer might already be on your phone/MacBook.

Re: Show HN: Apple Notes Liberator – Extract Notes.app Data and Save It as JSON

#23

I have published an app [Exporter]( https://apps.apple.com/us/app/exporter/id1099120373?mt=12 ) that does something similar - exports Apple Notes to HTML and markdown with the attachments. Give it a try, let me know if it solves your issue. Also, why did you select JSON as the output format?

Thanks for making your app. I’ve used it more than once and it works well. Many export solutions don’t handle attachments but yours does. So kudos for that.

A few years ago I tried to write my own exporter using AppleScript but got stuck by a showstopping bug in Notes AppleScript implementation. Or so it seemed. I hope that bug is fixed now. I just moved on to use your app instead.

Re: Show HN: Apple Notes Liberator – Extract Notes.app Data and Save It as JSON

#24
post #15

I wrote a similar tool in Python a few weeks ago, which uses AppleScript to liberate the data and saves it to a SQLite database: https://datasette.io/tools/apple-notes-to-sqlite I didn't actually know AppleScript before writing this tool... but it turned out ChatGPT knew it well enough to unblock me and provide me with exactly the code I needed to build the rest of the project! https://til.simonwillison.net/gpt3/chat…

A bit out of context, but did you know you can actually write OSA scripts using JS? In Script Editor there’s a menu where you can change the language.

Re: Show HN: Apple Notes Liberator – Extract Notes.app Data and Save It as JSON

#26
post #15

I wrote a similar tool in Python a few weeks ago, which uses AppleScript to liberate the data and saves it to a SQLite database: https://datasette.io/tools/apple-notes-to-sqlite I didn't actually know AppleScript before writing this tool... but it turned out ChatGPT knew it well enough to unblock me and provide me with exactly the code I needed to build the rest of the project! https://til.simonwillison.net/gpt3/chat…

From your article on how you wrote that:

> I've been stubbornly refusing to learn AppleScript for nearly twenty years at this point. Thanks to ChatGPT I can continue not to learn it, but I can now use it to solve problems

The Apple scripting stuff can also use JavaScript. It might be better to continue not to learn in JavaScript instead of AppleScript, if ChatGPT is as adept at Apple scripting in JavaScript as it seems to be in AppleScript.

That way if you want to tweak what ChatGPT gives you it will probably be easier. With AppleScript both interacting with other things and control flow or computation can be weird and confusing. With JavaScript at least the control flow and computation will likely be more normal.

Re: Show HN: Apple Notes Liberator – Extract Notes.app Data and Save It as JSON

#27
post #15

I wrote a similar tool in Python a few weeks ago, which uses AppleScript to liberate the data and saves it to a SQLite database: https://datasette.io/tools/apple-notes-to-sqlite I didn't actually know AppleScript before writing this tool... but it turned out ChatGPT knew it well enough to unblock me and provide me with exactly the code I needed to build the rest of the project! https://til.simonwillison.net/gpt3/chat…

Interesting. I was curious and wanted to achieve something similar with voice memos. I used the prompt "Write applescript to loop through all of my Apple Voice Memos" and the code it produced couldn't run in applescript.

Re: Show HN: Apple Notes Liberator – Extract Notes.app Data and Save It as JSON

#28

I am excited to see more solutions that work with Apple Notes database directly. This is my go-to application to capture unstructured memos while researching various topics. Last year I got carried away and built a simple site generator for Notes [0]. As a fun exercise I implemented ORM models to query Sqlite database in Ruby: User::Account.server(database: "tmp/test.sqlite").first. folders_dataset.offset(1).first no…

That is awesome! Thank you for sharing your notes on this :)

Re: Show HN: Apple Notes Liberator – Extract Notes.app Data and Save It as JSON

#30
post #8

Super interesting, particularly the link through to the blog with all the research into how Notes works. A particularly interesting thing that I don't see mentioned anywhere is that Apple Notes uses CRDTs (conflict free replicated data types) to enable both shared notes and multiple concurrent edits. With the CRDTs resolving the conflicts. It looks like the info on the page may be a good place to start looking to how…

CRDTs are definitely an “unsung hero” of Apple Notes… and a big reason why it is one Apple’s best “built-in” apps as of late.

A notes app that only works with one 2-trillion-dollar company's hardware and does not have builtin functionality to export notes (e.g. a menu option to do so) cannot reasonably be described as good. One's expectations have to be through the floor for that to be an honest appraisal.

Compare it to Obsidian, which just stores data in a bunch of markdown files on disk.

Post reply on HN