deploy-docs.yml 890 B

12345678910111213141516171819202122232425262728
  1. name: Deploy Docs
  2. on:
  3. repository_dispatch:
  4. types: request-build-reference # legacy
  5. schedule:
  6. - cron: '0 10 * * *' # Once per day at 10am UTC
  7. workflow_dispatch:
  8. permissions: read-all
  9. jobs:
  10. build:
  11. runs-on: ubuntu-latest
  12. if: github.repository_owner == 'spring-projects'
  13. steps:
  14. - name: Checkout
  15. uses: actions/checkout@v3
  16. with:
  17. ref: docs-build
  18. fetch-depth: 1
  19. - name: Dispatch (partial build)
  20. if: github.ref_type == 'branch'
  21. env:
  22. GH_TOKEN: ${{ secrets.GH_ACTIONS_REPO_TOKEN }}
  23. run: gh workflow run deploy-docs.yml -r $(git rev-parse --abbrev-ref HEAD) -f build-refname=${{ github.ref_name }}
  24. - name: Dispatch (full build)
  25. if: github.ref_type == 'tag'
  26. env:
  27. GH_TOKEN: ${{ secrets.GH_ACTIONS_REPO_TOKEN }}
  28. run: gh workflow run deploy-docs.yml -r $(git rev-parse --abbrev-ref HEAD)