Hi all,

I am looking for a local database that is easily accessible via the command line.

It can be SQL or non-SQL

Whats my use case? I want to use it kinda like a second brain. A place to save my notes, my todo lists, my book reading lists, links / articles to read later, etc.

I want it to be a good CLI citizen so that I can script its commands to create simpler abstractions, rather than writing out the full queries every time.

Maybe sqlite is what I need, but is that ideal for my use case?

Edit: removed notes, as evidently they aren’t suitable for this and aren’t like the rest.

  • Caveman@lemmy.world
    link
    fedilink
    arrow-up
    2
    ·
    edit-2
    2 months ago

    You can always log into a database and use raw SQL. For automation of your tasks you can put in some functions and stored procedures and later on you can always do something more graphical or even more SQL. You can do something like “exec create_note(‘Name of note’)” and “exec notes()” and whatnot.

    Then if you want to do something more elaborate than viewing tables and do some formatting programming languages are pretty nice do make stringified versions of the notes and a nice way to browse them.

    Then to finish up using some nice bash packages to create a CLI interface is very fun. I like charmbracelet’s stuff because it just looks nice and is easy to use. Here’s a thing you can use to create something to select a note to view: https://github.com/charmbracelet/gum