Skip to content

Commit

Permalink
Copy most recent version to latest on releases
Browse files Browse the repository at this point in the history
  • Loading branch information
discdiver authored Sep 9, 2023
1 parent 20ff883 commit c3e5943
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/build-docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,14 @@ jobs:
if [[ "$newest_release" == "$version" ]]; then
echo "Updating 'latest' docs version with $version."
mike deploy --config-file ./mkdocs.insiders.yml --update-aliases --branch $branch_name --prefix=versions "$display_name" latest
# There is a bug in Mike where image url aliases don't get rewritten to latest.
# As of Sept 2023 Mike version 1.2.
# Known issue that should be fixed in Mike 2.0.
# https://github.com/jimporter/mike/issues/157
# For now, copying the latest numbered version folder to "latest"
# so someone doesn't have to do it manually.
cp ./versions/"$version" ./versions/latest
else
echo "Updating previous docs version with $version."
mike deploy --config-file ./mkdocs.insiders.yml --update-aliases --branch $branch_name --prefix=versions "$display_name"
Expand Down

0 comments on commit c3e5943

Please sign in to comment.