Track changes to CLI tools by recording their help output
simonwillison.net
simonwillison.net
My scraper against the GitHub GraphQL schema catches some interesting details too: https://github.com/simonw/help-scraper/commits/main/github
The diff of a CLI help output is a lot more readable than the diff of a JSON file.
I did something a bit like this for a few internal tools I built at Airbnb. I built a docs system that indexed all the markdown files in every repo or project’s .infra/docs folder into a central documentation browser website.
Then in each tool project, we had a CI job that would loop over all the commands and spit the —-help output in Markdown format into that folder. That way when someone added commands or changed a command’s args or help text, the searchable docs were automatically updated.
We didn’t use this to generate a change log to show to users per se, but it did mean that you could run `git log .infra/docs` to see a log of every change to the tool’s interface.
For something like AWS, I guess you could do a changelog per service command? A changelog for the whole thing would be too detailed and contain too much stuff I don’t care about, I’d think.