Skip to content
2 min read
Bear-Lint

A small Markdown linter for Bear notes. It checks and fixes common Markdown inconsistencies — bullet markers, emphasis style, checklist syntax, heading structure, tags, and more — by reading and writing your notes directly via bearcli.

Usage

You can lint a single note by typing bear-lint <note-id>

screenshot of bear-lint linting a single note

… or lint all of your notes using bear-lint --all.

screenshot of bear-lint linting all notes

Add -o if you want a summary note in Bear, tagged #bear-lint, listing everything that changed.

screenshot of bear summary note

Commands

bear-lint --help                 # show all commands
bear-lint --version              # print the installed version
bear-lint <note-id>              # lint one note by ID
bear-lint --all                  # lint all notes (always asks for confirmation first)
bear-lint -a "#tag"              # -a is a short alias for --all
bear-lint --all "#tag"           # lint notes matching a Bear search query (also confirms first)
bear-lint --all "#tag" -y        # skip the confirmation prompt (cron/launchd-friendly)
bear-lint --selftest             # sanity check, no Bear needed
bear-lint <note-id> -o           # lint one note and also save the report as a Bear note
bear-lint --all "#tag" -o        # same, for a batch run
bear-lint <note-id> -n           # preview the diff without writing anything back
bear-lint --all -n               # preview every note's changes without writing (no prompt)

Download and links

Interested in this project? Check it out below.


Like what you're seeing?

If you're interested in my work and think we can collaborate on a cool project, get in touch with me!