I put together a library in Golang which lets you use Markdown in a literate programming style. Blockquotes and comments can specify associated actions, calling back into your Go code. This lets you create tutorials and scripts which can be viewed in a browser or run on the command line. We use this in the OpenZiti project (https://github.com/openziti/ziti) for our tutorials and demos. I thought others might be interested in using the code or even just the concept.
Thinking about this some more: I tend to be a 'scratch your own itch' type person, and I haven't had a place where I needed this elsewhere. I think it would work pretty well think anything that was wrapping a series of commands with a specific tool. The first thing that came to mind was docker. I could put together an example for how to do something simple in docker, maybe following the steps in https://docs.docker.com/get-started/02_our_app/. If that sounds interesting, let me know.