-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy path.goreleaser.yaml
230 lines (192 loc) · 5.1 KB
/
.goreleaser.yaml
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
# Make sure to check the documentation at https://goreleaser.com
release:
draft: true
replace_existing_draft: true
before:
hooks:
# You may remove this if you don't use go modules.
- go mod tidy
# you may remove this if you don't need go generate
- go generate ./...
builds:
- id: linux
main: ./cmd/tkey-ssh-agent
binary: tkey-ssh-agent
env:
- GOPROXY=https://proxy.golang.org,direct
- GOSUMDB=sum.golang.org
- CGO_ENABLED=0
goos:
- linux
goarch:
- amd64
- arm64
flags:
- -trimpath
- -buildvcs=false
# Custom ldflags mostly to avoid setting main.date which for some
# reason is default
ldflags:
-w -X main.version={{ .Version }} -X main.signerAppNoTouch= -buildid=
- id: darwin
main: ./cmd/tkey-ssh-agent
binary: tkey-ssh-agent
env:
- GOPROXY=https://proxy.golang.org,direct
- GOSUMDB=sum.golang.org
- CGO_ENABLED=1
goos:
- darwin
goarch:
- amd64
- arm64
flags:
- -trimpath
- -buildvcs=false
# Custom ldflags mostly to avoid setting main.date which for some
# reason is default
ldflags:
-w -X main.version={{ .Version }} -X main.signerAppNoTouch= -buildid=
- id: windows
main: ./cmd/tkey-ssh-agent
binary: tkey-ssh-agent
env:
- GOPROXY=https://proxy.golang.org,direct
- GOSUMDB=sum.golang.org
- CGO_ENABLED=0
goos:
- windows
goarch:
- amd64
- arm64
flags:
- -trimpath
- -buildvcs=false
# Custom ldflags mostly to avoid setting main.date which for some
# reason is default
ldflags:
-w -X main.version={{ .Version }} -X main.signerAppNoTouch= -buildid=
hooks:
pre: sh -c "cd ./cmd/tkey-ssh-agent && go-winres make --arch amd64"
- id: windows-tray
main: ./cmd/tkey-ssh-agent-tray
binary: tkey-ssh-agent-tray
env:
- GOPROXY=https://proxy.golang.org,direct
- GOSUMDB=sum.golang.org
- CGO_ENABLED=0
goos:
- windows
goarch:
- amd64
- arm64
flags:
- -trimpath
- -buildvcs=false
# Custom ldflags mostly to avoid setting main.date which for some
# reason is default
ldflags:
-w -H windowsgui -buildid=
hooks:
pre: sh -c "cd ./cmd/tkey-ssh-agent-tray && go-winres make --arch amd64"
universal_binaries:
- ids:
- darwin
replace: true
name_template: "tkey-ssh-agent"
hooks:
post: gon gon.hcl
archives:
- format: tar.gz
allow_different_binary_count: true
# this name template makes the OS and Arch compatible with the results of uname.
name_template: >-
{{ "tkey-ssh-agent" }}_
{{- .Version }}_
{{- title .Os }}_
{{- if eq .Arch "all" }}universal
{{- else }}{{ .Arch }}{{ end }}
{{- if .Arm }}v{{ .Arm }}{{ end }}
# use zip for windows archives
format_overrides:
- goos: windows
format: zip
files:
- src: system/tkey-ssh-agent.1
dst: man
strip_parent: true
nfpms:
# note that this is an array of nfpm configs
- #
# ID of the nfpm config, must be unique.
# Name of the package.
package_name: tkey-ssh-agent
# Your app's vendor.
vendor: Tillitis AB
# Your app's homepage.
homepage: https://tillitis.se/
# Your app's maintainer (probably you).
maintainer: Tillitis <[email protected]>
# Your app's description.
description: |-
SSH agent backed by Tillitis TKey
tkey-ssh-agent is an alternative SSH agent backed by a private ed25519 key
residing in the hardware TKey, a USB stick.
# Your app's license.
license: BSD-2-clause
# Formats to be generated.
formats:
- apk
- deb
- rpm
- archlinux # Since: v1.13
dependencies:
- pinentry-gnome3
bindir: /usr/bin
release: 1
section: misc
# Contents to add to the package.
# GoReleaser will automatically add the binaries.
contents:
- src: system/tkey-ssh-agent.1
dst: /usr/share/man/man1/tkey-ssh-agent.1
file_info:
mode: 0644
- src: system/tkey-ssh-agent.service
dst: /usr/lib/systemd/user/tkey-ssh-agent.service
file_info:
mode: 0644
- src: system/60-tkey.rules
dst: /usr/lib/udev/rules.d/60-tkey.rules
file_info:
mode: 0644
- src: system/copyright
dst: /usr/share/docs/tkey-ssh-agent/
file_info:
mode: 0644
overrides:
apk:
dependencies:
- pinentry-gnome
archlinux:
dependencies:
- pinentry
# Scripts to execute during the installation of the package. (overridable)
scripts:
postinstall: "system/postinst"
# Custom configuration applied only to the Deb packager.
deb:
# Lintian overrides
lintian_overrides:
- statically-linked-binary
- changelog-file-missing-in-native-package
checksum:
name_template: 'checksums.txt'
snapshot:
name_template: "{{ incpatch .Version }}-next"
changelog:
sort:
filters:
exclude:
- '^docs:'
- '^test:'