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@8d3c67de8e2fe68ef647c8db1e6a09f647780f40 # v2.19.0 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 }}"