Skip to content

Commit

Permalink
ci: Emit the snapshot flag during release when not triggered by a ver…
Browse files Browse the repository at this point in the history
…sion tag.
  • Loading branch information
jaqx0r committed Jan 4, 2023
1 parent 15b574a commit 54b11ec
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/release.yml
Expand Up @@ -12,8 +12,12 @@ permissions:

jobs:
goreleaser:
env:
flags: ""
runs-on: ubuntu-latest
steps:
- if: !startsWith(github.ref, 'refs/tags/v')
run: echo "flags=--snapshot" >> $GITHUB_ENV
- uses: actions/checkout@v3
with:
fetch-depth: 0
Expand All @@ -22,9 +26,9 @@ jobs:
with:
go-version-file: 'go.mod'
cache: true
- uses: goreleaser/goreleaser-action@v3
- uses: goreleaser/goreleaser-action@v4
with:
version: latest
args: release --rm-dist
args: release --rm-dist ${{ env.flags }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 54b11ec

Please sign in to comment.