diff --git a/.github/workflows/pull-request.yaml b/.github/workflows/pull-request.yaml index c599bcc..35285c8 100644 --- a/.github/workflows/pull-request.yaml +++ b/.github/workflows/pull-request.yaml @@ -10,7 +10,7 @@ jobs: name: Build runs-on: ubuntu-20.04 steps: - - name: Set up Go 1.16 + - name: Set up Go uses: actions/setup-go@v3 with: go-version: 1.18 @@ -26,10 +26,11 @@ jobs: sudo mv upx-3.96-amd64_linux/upx $(which upx) upx -V - name: Run GoReleaser - uses: goreleaser/goreleaser-action@v2.9.1 + uses: goreleaser/goreleaser-action@v4.1.1 with: - version: latest - args: release --skip-publish --rm-dist + github_token: ${{ secrets.GH_PUBLISH_SECRETS }} + version: v1.14.0 + args: release --skip-publish --rm-dist --snapshot - name: Test against the cmd run: | sudo ./release/http-downloader_linux_amd64_v1/hd install jenkins-zh/jenkins-cli/jcli @@ -49,7 +50,7 @@ jobs: name: Lint runs-on: ubuntu-20.04 steps: - - name: Set up Go 1.16 + - name: Set up Go uses: actions/setup-go@v3 with: go-version: 1.18 diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index c9fc5c1..b0c00d0 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -16,7 +16,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.18.x + go-version: 1.18 - name: Upgrade upx run: | # try to fix https://github.com/jenkins-zh/jenkins-cli/issues/493 @@ -32,9 +32,10 @@ jobs: docker login --username ${{ secrets.DOCKER_HUB_USER }} --password ${{secrets.DOCKER_HUB_TOKEN}} docker login ghcr.io/linuxsuren --username linuxsuren --password ${{secrets.GH_PUBLISH_SECRETS}} - name: Run GoReleaser - uses: goreleaser/goreleaser-action@v2.9.1 + uses: goreleaser/goreleaser-action@v4.1.1 with: - version: v1.14.1 + github_token: ${{ secrets.GH_PUBLISH_SECRETS }} + version: v1.14.0 args: release --rm-dist env: GITHUB_TOKEN: ${{ secrets.GH_PUBLISH_SECRETS }}