What did I make
I made plint, a linter for text documents.
There are many “linters” for programming languages so that you can know the error before compiling or building them. However, there are not so much “linters” for text documents and I wanted one (primarily for my school reports). The almost only thing that I could find was textlint, but their rules are written in JavaScript and I didn’t like that because the syntax for textlint rule looked a bit complicated.
With plint, you can create multiple rulesets and use them to lint text documents. There are also some specific functions for markdown files in the language (like md.headings) so you can even parse markdown files to look for errors.
What was challenging
I bet you would expect think the most challenging part would have been the language.
Actually I’d say the most challenging part was designing the CLI. I changed the structure of subcommands multiple times to get the most intuitive set of subcommands. I’m pretty satisfied with the outcome now.
What am I proud of
I am proud of the orthogonality of the language.
My language represents the range of the error using Match type. Some functions accept Match so that you can search inside the range. This makes it possible to combine multiple functions. For example, you can search for markdown headings first, and then look for “TODO” in the headings.
QoL improvements
I personally tested it for my recent reports and I found these QoL improvements:
- Quicker to check my reports before submission
- Cheaper than making AI check my reports
- Easier to create rules
Installation
PC with either macOS, Linux, or Windows.
You can install plint by using cargo, executing the install script (for macOS and Linux), or downloading the binary directly from Releases page.
- 15 devlogs
- 40h
- Frictionless