Skip to content

Commit b9094da

Browse files
committed
build: Add CI setup
1 parent b011020 commit b9094da

File tree

2 files changed

+58
-0
lines changed

2 files changed

+58
-0
lines changed

.github/workflows/ci.yml

+58
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
name: ci
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- master
7+
push:
8+
branches:
9+
- master
10+
11+
jobs:
12+
build:
13+
runs-on: ubuntu-18.04
14+
steps:
15+
-
16+
name: Checkout
17+
uses: actions/checkout@v2
18+
-
19+
name: Unshallow
20+
run: git fetch --prune --unshallow
21+
-
22+
name: Set up Go
23+
uses: actions/setup-go@v1
24+
with: # Ideally this should be picked up from .go-version rather than hard-coded
25+
go-version: 1.14.1
26+
-
27+
name: Snapshot build (cross-platform)
28+
uses: goreleaser/goreleaser-action@v1
29+
with:
30+
version: latest
31+
args: build --snapshot --skip-post-hooks
32+
33+
test:
34+
runs-on: ${{ matrix.os }}
35+
strategy:
36+
matrix:
37+
os:
38+
- ubuntu-18.04
39+
- windows-2019
40+
- macos-10.15
41+
steps:
42+
-
43+
name: Checkout
44+
uses: actions/checkout@v2
45+
-
46+
name: Unshallow
47+
run: git fetch --prune --unshallow
48+
-
49+
name: Set up Go
50+
uses: actions/setup-go@v1
51+
with: # Ideally this should be picked up from .go-version rather than hard-coded
52+
go-version: 1.14.1
53+
-
54+
name: Go mod verify
55+
run: go mod verify
56+
-
57+
name: Run tests
58+
run: make test
File renamed without changes.

0 commit comments

Comments
 (0)