name: Deploy Docs on: push: branches: - main permissions: contents: read jobs: deploy: runs-on: ubuntu-latest permissions: contents: write #needed to publish documentation steps: - uses: step-security/harden-runner@fe104658747b27e96e4f7e80cd0a94068e53901d # v2.16.1 with: egress-policy: audit - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 with: fetch-depth: 0 persist-credentials: false - name: Setup Go uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0 with: go-version-file: "go.mod" - name: Configure Git env: TOKEN: ${{ secrets.GITHUB_TOKEN }} GH_REPO: ${{ github.repository }} run: | git config user.name "$GITHUB_ACTOR" git config user.email "$GITHUB_ACTOR@users.noreply.github.com" git remote set-url origin "https://x-access-token:${TOKEN}@github.com/${GH_REPO}.git" - name: Build Docs run: make docs.publish env: GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"