docs.yml 1.0 KB

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