forked from elastic/harp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Taskfile.yml
40 lines (34 loc) · 1.16 KB
/
Taskfile.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
version: '3'
vars:
ARTIFACT: harp
tasks:
default:
cmds:
- task: build
compile:
desc: Compile artefact
cmds:
- go mod vendor
- mage compile
build:
desc: Build artefact
cmds:
- mage
release:
desc: Generate a release
cmds:
- go mod vendor
- mage release
release-pack:
desc: Generate final artefact to publish to GH
cmds:
- rm -rf dist && mkdir dist
- "tar cfJ dist/{{.ARTIFACT}}-darwin-amd64-$RELEASE.tar.xz -C bin {{.ARTIFACT}}-darwin-amd64"
- "tar cfJ dist/{{.ARTIFACT}}-linux-amd64-$RELEASE.tar.xz -C bin {{.ARTIFACT}}-linux-amd64"
- "tar cfJ dist/{{.ARTIFACT}}-linux-arm7-$RELEASE.tar.xz -C bin {{.ARTIFACT}}-linux-arm7"
- "tar cfJ dist/{{.ARTIFACT}}-linux-arm64-$RELEASE.tar.xz -C bin {{.ARTIFACT}}-linux-arm64"
- "tar cfJ dist/{{.ARTIFACT}}-windows-amd64-$RELEASE.tar.xz -C bin {{.ARTIFACT}}-windows-amd64.exe"
- cd dist && sha256sum {{.ARTIFACT}}-*.tar.xz > {{.ARTIFACT}}-checksum.txt
- cd dist && gpg --detach-sign --armor {{.ARTIFACT}}-checksum.txt
- cat dist/{{.ARTIFACT}}-checksum.txt
- mage homebrew > dist/{{.ARTIFACT}}.rb