From 269fc3b1bccc04c6abfe79f60e1a5fd3619faf32 Mon Sep 17 00:00:00 2001 From: Griatch Date: Sat, 13 Jun 2020 10:43:28 +0200 Subject: [PATCH] Changes to deploy mechanism --- .gitignore | 3 +++ docs/deploy.sh | 13 +++++++++---- docs/source/conf.py | 2 +- 3 files changed, 13 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 94c928843c..6641f347d9 100644 --- a/.gitignore +++ b/.gitignore @@ -47,3 +47,6 @@ nosetests.xml # Windows files generated during setup evennia.bat twistd.bat + +# never commit docs/build +docs/build diff --git a/docs/deploy.sh b/docs/deploy.sh index 05712c8111..ebb7e2aa2a 100644 --- a/docs/deploy.sh +++ b/docs/deploy.sh @@ -11,16 +11,21 @@ if [ -n "$(git status --untracked-files=no --porcelain)" ]; then fi git checkout gh-pages +# at this point we should be inside the docs/ folder of the gh-pages branch, +# with the build/ directory available since this is not in git -rm -Rf versions -mv build/html/versions . -git add versions +# remove all but the build dir +ls -Q | grep -v build | xargs rm -Rf + +mv build/html/versions/* . +# docs/build is in .gitignore so will not be included +git add . git commit -a -m "Updated HTML docs" git push origin gh-pages # get back to previous branch - git checkout - +git checkout - echo "Deployed to https://evennia.github.io/evennia-docs." diff --git a/docs/source/conf.py b/docs/source/conf.py index 1329aeab95..581c788d95 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -142,7 +142,7 @@ html_theme = 'alabaster' smv_tag_whitelist = r"^$" # smv_branch_whitelist = r"^static-file-docs$|^static-file-dev$" smv_branch_whitelist = r"^master$|^v1.0$" -smv_outputdir_format = "versions" + sep + "{config.release}" +smv_outputdir_format = "{config.release}" # recommonmark