Skip to content

Commit

Permalink
enable release publish on tag
Browse files Browse the repository at this point in the history
  • Loading branch information
mlsmaycon committed Apr 21, 2021
1 parent 75519d4 commit 51507a5
Showing 1 changed file with 6 additions and 12 deletions.
18 changes: 6 additions & 12 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,21 +1,19 @@
name: release
name: Release

on:
push:
branches:
- main
tags:
- 'v*'

jobs:
build:
release:
runs-on: ubuntu-latest
steps:
-
name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
fetch-depth: 0 # It is required for GoReleaser to work properly
-
name: Set up Go
uses: actions/setup-go@v2
Expand All @@ -35,13 +33,9 @@ jobs:
-
name: Run GoReleaser
uses: goreleaser/goreleaser-action@v2
#if: startsWith(github.ref, 'refs/tags/')
if: startsWith(github.ref, 'refs/tags/')
with:
version: latest
args: --snapshot --skip-publish --rm-dist
args: release --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

-
name: Check dist directory
run: ls -lhR dist/
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 51507a5

Please sign in to comment.