HNHacker News
TopNewBestAskShowJobs

xwmx

122 karma · joined April 4, 2020

submissionscomments
xwmx··on Show HN: CLI plain-text notes & bookmarks with Git, sync, encryption, and more
Portability, philosophy, style. I find that designing within constraints can lead to interesting solutions, and this project has focused on embracing and leveraging the command line interface itself.
xwmx··on Show HN: CLI plain-text notes & bookmarks with Git, sync, encryption, and more
FWIW, the core idea in `nb` is that it grew out of exactly that toolset and philosophy and develops it into a single, streamlined interface with a bunch of conveniences and features. It embraces that model and is intended to support it.
xwmx··on Show HN: CLI plain-text notes & bookmarks with Git, sync, encryption, and more
Indeed, it is, and you can do exactly that.
xwmx··on Show HN: CLI plain-text notes & bookmarks with Git, sync, encryption, and more
Cool, your use case is exactly one I hope it works for. I find that the notebooks are a really good way to organize by topic or project, and should work really well for classes, too. You can even archive a project or class notebook when it ends and still easily access, revive, or drop into the content.

Tagging in `nb` is really simple and is just a matter of putting hashtags in your documents and then searching for those hashtags using `nb search` / `nb q`. `nb <url>` makes tagging a little more convenient when bookmarking by providing a `-t <tag1>,<tag2>...` / `--tags <tag1>,<tag2>...` option and saving them in a dedicated `## Tags` section in `.bookmark.md` documents.

xwmx··on Show HN: CLI plain-text notes & bookmarks with Git, sync, encryption, and more
Very cool. `pass` is awesome and I didn't realize it had the `pass edit` feature. I have written scripts that use the 1Password and Keychain command line tools, and I definitely want `nb` to use all three of these, maybe via a plugin.
xwmx··on Show HN: CLI plain-text notes & bookmarks with Git, sync, encryption, and more
Yeah, it's a little unusual. No big story. I just did an early version and then didn't update it for a long time, then got hooked on working on it again over the past few months.

I don't know what to say about the number of commits. My working style on this project has involved a lot of smaller commits and little feature iterations, maybe because of the single big script and single big README, or maybe something about the feedback loop of this style of development.

xwmx··on Show HN: CLI plain-text notes & bookmarks with Git, sync, encryption, and more
That particular function, `nb show`, is a big `if` statement checking the file type and environment for available tools. I'm more than happy for suggestions and / or pull requests for optimizing that.

Note that Bash is a weird language that doesn't provide language features found in normal languages, and this targets old Bash which doesn't even have associative arrays, so there are things that might look "wrong", but aren't necessarily in this context. That's a big part of what makes it interesting to code in.

xwmx··on Show HN: CLI plain-text notes & bookmarks with Git, sync, encryption, and more
Thanks! That looks really interesting and very nicely designed (both your CLI and the web app).

It should be pretty easy to create a bookmark import plugin for `nb`, so that's likely to happen.