Skip to content

Commit 4df84c9

Browse files
committed
added automatic releases using goreleaser
1 parent dde41bd commit 4df84c9

File tree

3 files changed

+47
-2
lines changed

3 files changed

+47
-2
lines changed

.github/main.workflow

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,23 @@
1-
workflow "Quality" {
1+
workflow "Build" {
22
on = "push"
3-
resolves = ["test"]
3+
resolves = ["test", release"]
44
}
55
66
action "test" {
77
uses = "actions/docker/cli@master"
88
args = "build --target acceptance ."
99
}
1010
11+
action "is-tag" {
12+
uses = "actions/bin/filter@master"
13+
args = "tag"
14+
}
15+
16+
action "release" {
17+
uses = "docker://goreleaser/goreleaser"
18+
secrets = [
19+
"GITHUB_TOKEN",
20+
]
21+
args = "release"
22+
needs = ["test", "is-tag"]
23+
}

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
conftest
22
TODO.md
3+
dist

.goreleaser.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
before:
2+
hooks:
3+
- go mod download
4+
builds:
5+
- env:
6+
- CGO_ENABLED=0
7+
goos:
8+
- windows
9+
- linux
10+
- darwin
11+
archive:
12+
replacements:
13+
darwin: Darwin
14+
linux: Linux
15+
windows: Windows
16+
386: i386
17+
amd64: x86_64
18+
format: tar.gz
19+
format_overrides:
20+
- goos: windows
21+
format: zip
22+
checksum:
23+
name_template: 'checksums.txt'
24+
snapshot:
25+
name_template: "{{ .Tag }}-next"
26+
changelog:
27+
sort: asc
28+
filters:
29+
exclude:
30+
- '^docs:'
31+
- '^test:'

0 commit comments

Comments
 (0)