# Gitea Actions workflow (Gitea 1.21 or later with a registered act_runner). # Publishes a release on this Gitea server (.goreleaser.yaml, gitea_urls). # Repository secrets: GITEA_TOKEN (a token with write access to releases), # COSIGN_PRIVATE_KEY and COSIGN_PASSWORD (the project's cosign key). name: release on: push: tags: ["v*"] jobs: release: runs-on: ubuntu-latest steps: - uses: https://gitea.com/actions/checkout@v4 with: fetch-depth: 0 - uses: https://gitea.com/actions/setup-go@v5 with: go-version-file: go.mod - run: go test -count=1 ./... - run: go install github.com/CycloneDX/cyclonedx-gomod/cmd/cyclonedx-gomod@v1.12.0 - run: go install github.com/sigstore/cosign/v2/cmd/cosign@v2.6.5 - run: go install github.com/goreleaser/goreleaser/v2@v2.18.2 - run: goreleaser release --clean env: GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }} COSIGN_PRIVATE_KEY: ${{ secrets.COSIGN_PRIVATE_KEY }} COSIGN_PASSWORD: ${{ secrets.COSIGN_PASSWORD }}