From 40093a9878be6d5c646447ec1f608ad322a0fbb9 Mon Sep 17 00:00:00 2001 From: Philippe Tillet Date: Wed, 9 Feb 2022 01:32:41 -0800 Subject: [PATCH] [DOCS] Multiple versions are now supported (#457) --- .github/workflows/documentation.yml | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 6d06c96d1..e921709ba 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -12,7 +12,7 @@ jobs: steps: - + - name: Checkout gh-pages uses: actions/checkout@v1 with: @@ -21,21 +21,30 @@ jobs: - name: Checkout branch uses: actions/checkout@v1 - - name: Install Triton - run: | - alias python='python3' - cd python - pip3 install -e '.[tutorials]' - - name: Build docs run: | + git fetch origin master:master cd docs sphinx-multiversion . _build/html/ - name: Publish docs run: | + git branch + # update docs + rm -r /tmp/triton-docs; + mkdir /tmp/triton-docs; + mv docs/_build/html/* /tmp/triton-docs/ git checkout gh-pages - sh ./update-website.sh + cp -r CNAME /tmp/triton-docs/ + cp -r index.html /tmp/triton-docs/ + cp -r .nojekyll /tmp/triton-docs/ + rm -r * + cp -r /tmp/triton-docs/* . + # ln -s master/index.html . + # mv master docs + git add . + git commit -am "[GH-PAGES] Updated website" + # publish docs eval `ssh-agent -s` DISPLAY=:0 SSH_ASKPASS=~/.ssh/give_pass.sh ssh-add ${{ secrets.SSH_KEY }} <<< ${{ secrets.SSH_PASS }} git remote set-url origin git@github.com:openai/triton.git