Cog resurgence | Ned Batchelder

submited by
Style Pass
2022-01-15 02:00:05

My cog tool has been having a resurgence of late: a number of people are discovering it’s useful to run a little bit of Python code inside otherwise static files.

It took cog 17 years to become an overnight success :) (first posted Feb 2004:

As a test balloon, I’ve switched structlog from to flit w/ pyproject.toml in combination with @nedbat’s cog to maintain some deduplication. I think I like it! Sharp tools that do one thing well FTW.

I’ve been solving so many documentation problems with @nedbat’s cog tool recently - it’s fantastic for keeping documentation automatically up-to-date, in Markdown or rST) Here’s a new page of sqlite-utils docs showing --help for every CLI command!

A quick, public thanks to @nedbat for creating Cog; I did the “trendy” thing and used Cog to automate the README for the Python Launcher for Unix (instead of using my home-grown solution). Makes editing the README simple again!

Leave a Comment