diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c845bcc..4147598 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,7 +11,7 @@ on: - main env: - GO_VERSION: '1.22' + GO_VERSION: "1.22" concurrency: group: ${{ github.workflow }}-${{ github.ref }} @@ -40,7 +40,7 @@ jobs: env: CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} - publish: + publish-linux: needs: build runs-on: ubuntu-latest if: startsWith(github.ref, 'refs/tags/') @@ -48,7 +48,6 @@ jobs: permissions: contents: write packages: write - pull-requests: write steps: - uses: actions/checkout@v4 @@ -86,8 +85,37 @@ jobs: with: distribution: goreleaser version: latest - args: release --clean + args: release --skip chocolatey env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_STORE_CREDENTIALS }} + + publish-windows: + needs: build + runs-on: windows-latest + if: startsWith(github.ref, 'refs/tags/') + + permissions: + contents: write + packages: write + + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - run: git fetch --force --tags + + - name: Setup Go environment + uses: actions/setup-go@v5 + with: + go-version: ${{ env.GO_VERSION }} + + - uses: goreleaser/goreleaser-action@v5 + with: + distribution: goreleaser + version: latest + args: release --skip publish,snapcraft,docker,homebrew + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} CHOCOLATEY_API_KEY: ${{ secrets.CHOCOLATEY_API_KEY }} diff --git a/.goreleaser.yaml b/.goreleaser.yaml index 6c0f11e..9784a07 100644 --- a/.goreleaser.yaml +++ b/.goreleaser.yaml @@ -50,7 +50,7 @@ brews: email: emmanuel@cerberauth.com chocolateys: - - name: "{{ .ProjectName }}" + - name: vulnapi owners: CerberAuth authors: Emmanuel Gautier project_url: https://vulnapi.cerberauth.com/ @@ -64,8 +64,6 @@ chocolateys: summary: VulnAPI is an open-source project designed to help you scan your APIs for common security vulnerabilities and weaknesses. description: | VulnAPI is an open-source project designed to help you scan your APIs for common security vulnerabilities and weaknesses. - dependencies: - - id: nfpm nfpms: - package_name: "{{ .ProjectName }}" diff --git a/go.sum b/go.sum index a5adf9b..557ce7f 100644 --- a/go.sum +++ b/go.sum @@ -55,8 +55,6 @@ github.com/spf13/cobra v1.8.0 h1:7aJaZx1B85qltLMc546zn58BxxfZdR/W22ej9CFoEf0= github.com/spf13/cobra v1.8.0/go.mod h1:WXLWApfZ71AjXPya3WOlMsY9yMs7YeiHhFVlvLyhcho= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= -github.com/std-uritemplate/std-uritemplate/go v0.0.54 h1:8t7J7tNuMDj4Vkqq+IRENQDZTZzXJZZbN+iD60PEiAs= -github.com/std-uritemplate/std-uritemplate/go v0.0.54/go.mod h1:CLZ1543WRCuUQQjK0BvPM4QrG2toY8xNZUm8Vbt7vTc= github.com/std-uritemplate/std-uritemplate/go v0.0.55 h1:muSH037g97K7U2f94G9LUuE8tZlJsoSSrPsO9V281WY= github.com/std-uritemplate/std-uritemplate/go v0.0.55/go.mod h1:rG/bqh/ThY4xE5de7Rap3vaDkYUT76B0GPJ0loYeTTc= github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg=