diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 000000000..328ef117f --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,31 @@ +name: Release Go project + +on: + push: + tags: + - "*" # triggers only if push new tag version + +jobs: + build: + name: GoReleaser build + runs-on: ubuntu-latest + + steps: + - name: Check out code into the Go module directory + uses: actions/checkout@v2 + with: + fetch-depth: 0 # See: https://goreleaser.com/ci/actions/ + + - name: Set up Go 1.14 + uses: actions/setup-go@v2 + with: + go-version: 1.14 + id: go + + - name: Run GoReleaser + uses: goreleaser/goreleaser-action@master + with: + version: latest + args: release --rm-dist + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.goreleaser.yml b/.goreleaser.yml index 05915084e..dd9b7d6c7 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -29,8 +29,6 @@ archives: amd64: x86_64 files: - LICENSE -snapshot: - name_template: "{{ .Tag }}-SNAPSHOT" changelog: sort: asc filters: