docs.yml 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. name: github pages
  2. on:
  3. push:
  4. paths:
  5. - docs/**
  6. - .github/workflows/docs.yml
  7. branches:
  8. - master
  9. jobs:
  10. build-deploy:
  11. runs-on: ubuntu-latest
  12. environment: docs
  13. steps:
  14. - uses: actions/checkout@v2
  15. - name: Setup mdBook
  16. uses: peaceiris/actions-mdbook@v1
  17. with:
  18. mdbook-version: "0.4.10"
  19. - name: Build
  20. run: cd docs &&
  21. cd guide && mdbook build -d ../nightly/guide && cd .. &&
  22. cd reference && mdbook build -d ../nightly/reference && cd .. &&
  23. cd router && mdbook build -d ../nightly/router && cd ..
  24. - name: Deploy 🚀
  25. uses: JamesIves/github-pages-deploy-action@v4.2.3
  26. with:
  27. branch: gh-pages # The branch the action should deploy to.
  28. folder: docs/nightly # The folder the action should deploy.
  29. target-folder: docs/nightly
  30. repository-name: dioxuslabs/docsite
  31. clean: false
  32. token: ${{ secrets.DEPLOY_KEY }} # let's pretend I don't need it for now