Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document multiple versions of a project #217

Closed
H4dr1en opened this issue Jun 16, 2020 · 3 comments
Closed

Document multiple versions of a project #217

H4dr1en opened this issue Jun 16, 2020 · 3 comments
Labels
question Not a bug, but a FAQ entry

Comments

@H4dr1en
Copy link

H4dr1en commented Jun 16, 2020

Hi,

First of all: thanks for the great work!

I would like have CI/CD of the documentation of my projects in a private static website and I am looking for a way to navigate between the different versions of the projects. Something close to what readthedocs provides.

My first guess was to have the documentation built for each version in different subfolders and edit the mako templates to show this kind of dropdown bar with the list of available version.

Is there a more straightfoward /already available/recommended way to achieve this?

@kernc
Copy link
Member

kernc commented Jun 16, 2020

Thanks! Nothing so far. Your approach seems reasonable. Checking out tagged releases and generating output in versioned subfolders, all the while injecting a common header switcher template seems doable rather easily in a few straightforward lines of POSIX shell.

You're strongly encouraged to share your recipe afterwards! 😃

@kernc kernc added the question Not a bug, but a FAQ entry label Jun 16, 2020
@rozsasarpi
Copy link

In our projects -- hosted on GitLab -- we solved this with using GitLab pages and Environments, see e.g.
https://stackoverflow.com/questions/55596789/deploying-gitlab-pages-for-different-branches/58402821#58402821

Currently we automatically generate a unique static documentation page (using pdoc3) for each branch. It is not a perfect solution but it does the job and easy to set up. I cannot share an example project as they are all private ones but I can give guidance if this approach would suit your needs.

@kernc kernc changed the title Multiple versions of a project Document multiple versions of a project Jun 25, 2020
@kernc kernc pinned this issue Jun 25, 2020
@H4dr1en
Copy link
Author

H4dr1en commented Oct 23, 2020

Thanks for your answers! I ended up with the following setup:

  • a bash script that pulls a repo, checkout the different tags and retrieve the /docs folder of each git tag.
  • a cron job per repo that calls this bash script periodically
  • a caddy file server to browse the folder where all repos and versions are stored

@H4dr1en H4dr1en closed this as completed Oct 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Not a bug, but a FAQ entry
Development

No branches or pull requests

3 participants