-
I'm looking for recommendations on how to remove versions from a Mkdocs site published with GHA. I have two scenarios where I need things deleted -- a one time process because of a mistake in initial deploying the site, and the other -- an ongoing need to remove "release candidate" builds. GitHub repo: https://github.com/hyperledger/aries-cloudagent-python I specifically want to remove the version "docs-v0.12.0rc1" as it was created while I was trying to figure out the best flow for our situation. We publish "Release Candidates" such as 0.12.0rc1, 0.12.0rc2. As we finalize the release (e.g., when 0.12.0 is released), I'd like to remove the release candidate docs from the published site. Is there a recommend way to do that? Ideas I've had:
Suggestions would be welcome! Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
For one-off cases, you can just do it all locally via For clearing RCs in general, why not just write a small script that runs in your CI when you tag the final version? You can use |
Beta Was this translation helpful? Give feedback.
-
Good ideas. Thanks for the suggestions — good ones. The first sounds much better than the I think the loop idea is a good one. Delete is only called when needed, but can always be part of the script. Thanks! |
Beta Was this translation helpful? Give feedback.
-
Actually — I’m not quite clear on the logistics of the one-off. Assuming I have a fork, is the process:
When I run locally, I don’t touch the gh-pages branch, so wanted to be sure of the process. I still don’t quite understand the magic that mike is doing :-) Thanks! |
Beta Was this translation helpful? Give feedback.
For one-off cases, you can just do it all locally via
mike delete
, and push back upstream.For clearing RCs in general, why not just write a small script that runs in your CI when you tag the final version? You can use
mike list --json
to get all the versions in JSON format (this is just yourversions.json
file on thegh-pages
branch), and then loop through them to pick out any versions to be deleted. Then callmike delete <each-version>
.