Hacker News new | ask | show | jobs
by bryanlarsen 4466 days ago
A few years ago I created a tutorial[1] using a similar mechanism. I put the tutorial text in the commit message as markdown, then created a script to create a tutorial from the git history.

Besides the benefits to readers in having git diffs available and being able to "skip steps" by replaying history, it made the tutorial much easier to keep up to date because it was working code.

I used stacked git[2] to make it easy to arbitrarily edit the git history.

compare the tutorial history[3] with the real history[4]

[1]: http://hobocentral.net/tutorials/agility [2]: http://www.procode.org/stgit/ [3]: https://github.com/Hobo/agility-gitorial [4]: https://github.com/Hobo/agility-gitorial-patches