Currently, the book is being published to github pages on any new version tags pushed to the repo. This is a good starting point for automatic releases, but ideally there should be some versioning mechanism in the resulting website.
Two big use cases for this
users of older versions of the plugin should be able to read the corresponding version of the book
it's handy to be able to preview newer versions of the book in the actual environment it will be published in as the plugin/book develops
Since github pages uses static files for rendering, I don't think this is too unreasonable. In the pages branch, each version-tag-publish of the book could produce a new directory named after the version. Then, each push to main could publish the book to a main directory in the pages branch. A latest directory could redirect to the most-recently-published version-tag of the book. Then, the index.html of the entire pages branch could either have a list of all of these, or just redirect to latest.
Currently, the book is being published to github pages on any new version tags pushed to the repo. This is a good starting point for automatic releases, but ideally there should be some versioning mechanism in the resulting website. Two big use cases for this
Since github pages uses static files for rendering, I don't think this is too unreasonable. In the pages branch, each version-tag-publish of the book could produce a new directory named after the version. Then, each push to main could publish the book to a
main
directory in the pages branch. Alatest
directory could redirect to the most-recently-published version-tag of the book. Then, the index.html of the entire pages branch could either have a list of all of these, or just redirect to latest.This seems to have been accomplished before, and we may be able to use existing technologies like https://github.com/koumoul-dev/gh-pages-multi
Ideally, the other versions of the book would somehow be discoverable from each version of the book.