docs.yml 917 B

12345678910111213141516171819202122232425262728293031323334353637
  1. name: Deploy Docs
  2. on:
  3. push:
  4. branches:
  5. - main
  6. permissions:
  7. contents: read
  8. jobs:
  9. deploy:
  10. runs-on: ubuntu-latest
  11. permissions:
  12. contents: write #needed to publish documentation
  13. steps:
  14. - uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
  15. with:
  16. egress-policy: audit
  17. - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
  18. with:
  19. fetch-depth: 0
  20. - name: Setup Go
  21. uses: actions/setup-go@4dc6199c7b1a012772edbd06daecab0f50c9053c # v6.1.0
  22. with:
  23. go-version-file: "go.mod"
  24. - name: Configure Git
  25. run: |
  26. git config user.name "$GITHUB_ACTOR"
  27. git config user.email "$GITHUB_ACTOR@users.noreply.github.com"
  28. - name: Build Docs
  29. run: make docs.publish
  30. env:
  31. GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"