Skip to content

Commit

Permalink
adjusted workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
TheFireMike committed Dec 16, 2020
1 parent a8af2aa commit 70db765
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 40 deletions.
10 changes: 2 additions & 8 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,16 @@ on:
push:
branches:
- '*'
pull_request:
branches:
- '*'

jobs:

build:
name: Build
runs-on: ubuntu-latest
steps:

- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.13
id: go
go-version: ^1.14

- name: Check out code into the Go module directory
uses: actions/checkout@v2
Expand All @@ -39,4 +33,4 @@ jobs:
run: go build -v .

- name: Build client
run: go build -tags client -v .
run: go build -tags client -v .
5 changes: 1 addition & 4 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ on:
push:
branches:
- '*'
pull_request:
branches:
- '*'

jobs:
fmt:
Expand All @@ -31,4 +28,4 @@ jobs:
uses: grandcolline/golang-github-actions@v1.1.0
with:
run: vet
token: ${{ secrets.GITHUB_TOKEN }}
token: ${{ secrets.GITHUB_TOKEN }}
19 changes: 7 additions & 12 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,31 +10,26 @@ jobs:
name: Release
runs-on: ubuntu-latest
steps:
-
name: Checkout
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0

-
name: Set up Go
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.14
go-version: ^1.14

-
name: Generate configs
- name: Generate configs
run: go generate

-
name: Tidy go mod
- name: Tidy go mod
run: go mod tidy

-
name: Run GoReleaser
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: release --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
8 changes: 1 addition & 7 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,16 @@ on:
push:
branches:
- '*'
pull_request:
branches:
- '*'

jobs:

test:
name: Test
runs-on: ubuntu-latest
steps:

- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.13
id: go
go-version: ^1.14

- name: Check out code into the Go module directory
uses: actions/checkout@v2
Expand Down
14 changes: 5 additions & 9 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
builds:
- id: "thola"

goos:
- linux
ignore:
- goos: linux
goarch: 386
Expand All @@ -15,12 +13,10 @@ builds:
ldflags:
- -s -w
env:
- CGO_ENABLED=1
- CGO_ENABLED=0

- id: "thola-client"

goos:
- linux
ignore:
- goos: linux
goarch: 386
Expand All @@ -29,17 +25,17 @@ builds:
binary: thola-client

flags:
- -tags
- client
- -tags=client
ldflags:
- -s -w
env:
- CGO_ENABLED=1
- CGO_ENABLED=0

archives:
- builds:
- thola
- thola-client

replacements:
amd64: 64-bit
amd64: 64-bit
darwin: macOS

0 comments on commit 70db765

Please sign in to comment.