Check out How to create a versioned docs site with Jekyll by annegentle. Here is an excerpt:
Versions of software product or a service need documentation sites to match those version numbers. As I investigated and learned more, I found layers of complexity when using a source control…
The full article is available here.