The source code and dockerfile for the GSW2024 AI Lab.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

61 lines
1.5 KiB

2 months ago
  1. name: Docs Versioning
  2. on:
  3. push:
  4. tags:
  5. - 'v?*.*.*'
  6. permissions:
  7. contents: write
  8. jobs:
  9. docs:
  10. name: Generate Website for new version
  11. runs-on: ubuntu-latest
  12. env:
  13. SPHINX_GITHUB_CHANGELOG_TOKEN: ${{ secrets.GITHUB_TOKEN }}
  14. steps:
  15. - uses: actions/checkout@v3
  16. - uses: actions/setup-python@v4
  17. with:
  18. python-version: '3.9'
  19. - name: Get tag
  20. id: tag
  21. uses: dawidd6/action-get-tag@v1
  22. - name: Install dependencies
  23. run: pip install -r docs/requirements.txt
  24. - name: Register Envs
  25. run: pip install -e .
  26. - name: Build Envs Docs
  27. run: python docs/_scripts/gen_env_docs.py
  28. - name: Build Envs Display
  29. run: python docs/_scripts/gen_envs_display.py
  30. - name: Build
  31. run: sphinx-build -b dirhtml -v docs _build
  32. - name: Move 404
  33. run: mv _build/404/index.html _build/404.html
  34. - name: Update 404 links
  35. run: python docs/_scripts/move_404.py _build/404.html
  36. - name: Remove .doctrees
  37. run: rm -r _build/.doctrees
  38. - name: Upload to GitHub Pages
  39. uses: JamesIves/github-pages-deploy-action@v4
  40. with:
  41. folder: _build
  42. target-folder: ${{steps.tag.outputs.tag}}
  43. clean: false
  44. - name: Upload to GitHub Pages
  45. uses: JamesIves/github-pages-deploy-action@v4
  46. with:
  47. folder: _build
  48. clean-exclude: |
  49. *.*.*/
  50. main