Add step for snapshot (#10736)
Only run release steps on tags to avoid failure
This commit is contained in:
parent
d96dcde1ba
commit
cd6804b49b
1 changed files with 11 additions and 0 deletions
11
.github/workflows/plugin.yaml
vendored
11
.github/workflows/plugin.yaml
vendored
|
@ -22,7 +22,17 @@ jobs:
|
|||
go-version: '1.21.5'
|
||||
check-latest: true
|
||||
|
||||
- name: Run GoReleaser Snapshot
|
||||
if: ${{ ! startsWith(github.ref, 'refs/tags/') }}
|
||||
uses: goreleaser/goreleaser-action@7ec5c2b0c6cdda6e8bbb49444bc797dd33d74dd8 # v5.0.0
|
||||
with:
|
||||
version: latest
|
||||
args: release --snapshot --clean
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Run GoReleaser
|
||||
if: ${{ startsWith(github.ref, 'refs/tags/') }}
|
||||
uses: goreleaser/goreleaser-action@7ec5c2b0c6cdda6e8bbb49444bc797dd33d74dd8 # v5.0.0
|
||||
with:
|
||||
version: latest
|
||||
|
@ -31,6 +41,7 @@ jobs:
|
|||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Update new version in krew-index
|
||||
if: ${{ startsWith(github.ref, 'refs/tags/') }}
|
||||
uses: rajatjindal/krew-release-bot@df3eb197549e3568be8b4767eec31c5e8e8e6ad8 # v0.0.46
|
||||
with:
|
||||
krew_template_file: cmd/plugin/krew.yaml
|
||||
|
|
Loading…
Reference in a new issue