Set correct goreleaser version and run on push (#267)

Set the correct goreleaser version with v prefix
and enable run the pipeline on every push
This commit is contained in:
Maycon Santos 2022-03-14 13:38:06 +01:00 committed by GitHub
parent 1660a915e2
commit 3a69f334e8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 41 deletions

View File

@ -1,40 +0,0 @@
name: Test Build On Platforms
on: [pull_request]
jobs:
test_build:
strategy:
matrix:
os: [ windows, linux, darwin ]
go-version: [1.17.x]
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: ${{ matrix.go-version }}
- name: Cache Go modules
uses: actions/cache@v2
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-test-${{ matrix.os }}-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-test-${{ matrix.os }}
- name: Install modules
run: GOOS=${{ matrix.os }} go mod tidy
- name: run build client
run: GOOS=${{ matrix.os }} go build .
working-directory: client
- name: run build management
run: GOOS=${{ matrix.os }} go build .
working-directory: management
- name: run build signal
run: GOOS=${{ matrix.os }} go build .
working-directory: signal

View File

@ -4,6 +4,9 @@ on:
push:
tags:
- 'v*'
branches:
- main
pull_request:
jobs:
release:
@ -50,7 +53,7 @@ jobs:
name: Run GoReleaser
uses: goreleaser/goreleaser-action@v2
with:
version: 1.6.3
version: v1.6.3
args: release --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}