-
-
Notifications
You must be signed in to change notification settings - Fork 3
/
.goreleaser.yml
327 lines (302 loc) · 10.8 KB
/
.goreleaser.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
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
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
# Release Configuration
project_name: waku
report_sizes: true
version: 2
before:
hooks:
- go mod tidy
- ./scripts/completions.sh
- ./scripts/manpages.sh
builds:
- env:
- CGO_ENABLED=0
goos:
- linux
- darwin
- windows
goarch:
- "386"
- amd64
- arm
- arm64
- ppc64
goarm:
- "7"
ignore:
- goos: windows
goarch: arm
mod_timestamp: "{{ .CommitTimestamp }}"
flags:
- -trimpath
universal_binaries:
- replace: false
# Lets disable this for now and follow goreleaser upstream https://github.com/goreleaser/goreleaser/blob/main/.goreleaser.yaml#L67
# upx:
# - ids: [default]
# enabled: true
# compress: best
# lzma: true
# brute: true
# goos: [linux, windows] # skip darwin (macOS 13.x Ventura is not support now)
# goarch: [amd64, arm64]
archives:
- name_template: >-
{{- .ProjectName }}_
{{- title .Os }}_
{{- if eq .Arch "amd64" }}x86_64
{{- else if eq .Arch "386" }}i386
{{- else }}{{ .Arch }}{{ end }}
{{- if .Arm }}v{{ .Arm }}{{ end -}}
format_overrides:
- goos: windows
format: zip
builds_info:
group: root
owner: root
mtime: "{{ .CommitDate }}"
files:
- src: README.md
info:
owner: root
group: root
mtime: "{{ .CommitDate }}"
- src: LICENSE
info:
owner: root
group: root
mtime: "{{ .CommitDate }}"
- src: completions/*
info:
owner: root
group: root
mtime: "{{ .CommitDate }}"
- src: manpages/*
info:
owner: root
group: root
mtime: "{{ .CommitDate }}"
aurs:
- name: waku-bin
homepage: https://github.com/caffeine-addictt/waku
description: A simple template repository generator. Lets make starting new projects feel like a breeze again!
maintainers:
- Jun Xiang <contact@ngjx.org>
private_key: "{{ .Env.AUR_PRIVATE_KEY }}"
license: AGPL-3.0
git_url: "ssh://aur@aur.archlinux.org/waku-bin.git"
skip_upload: false
depends:
- git
package: |-
# bin
install -Dm755 "./waku" -t "$pkgdir/usr/bin"
# license
install -Dm644 "./LICENSE" "$pkgdir/usr/share/licenses/waku"
# completions
mkdir -p "${pkgdir}/usr/share/bash-completion/completions/"
mkdir -p "${pkgdir}/usr/share/zsh/site-functions/"
mkdir -p "${pkgdir}/usr/share/fish/vendor_completions.d/"
install -Dm644 "./completions/waku.bash" "$pkgdir/usr/share/bash-completion/completions/waku"
install -Dm644 "./completions/waku.zsh" "$pkgdir/usr/share/zsh/site-functions/_waku"
install -Dm644 "./completions/waku.fish" "$pkgdir/usr/share/fish/vendor_completions.d/waku.fish"
# man page
mkdir -p "$pkgdir/usr/share/man/man1"
install -Dm644 "./manpages/waku.1.gz" "$pkgdir/usr/share/man/man1/waku.1.gz"
commit_author:
name: goreleaserbot
email: bot@goreleaser.com
url_template: "https://github.com/caffeine-addictt/waku/releases/download/{{ .Tag }}/{{ .ArtifactName }}"
dockers:
- image_templates:
- "caffeinec/waku:{{ .Tag }}-amd64"
- "ghcr.io/caffeine-addictt/waku:{{ .Tag }}-amd64"
skip_push: false
dockerfile: Dockerfile.release
use: buildx
build_flag_templates:
- "--pull"
- "--label=io.artifacthub.package.readme-url=https://raw.githubusercontent.com/caffeine-addictt/waku/main/README.md"
- "--label=io.artifacthub.package.logo-url=https://waku.ngjx.org/static/logo.png"
- '--label=io.artifacthub.package.maintainers=[{"name":"Jun Xiang","email":"contact@ngjx.org"}]'
- "--label=io.artifacthub.package.license=AGPL-3.0"
- "--label=org.opencontainers.image.description=A simple template repository generator. Lets make starting new projects feel like a breeze again!"
- "--label=org.opencontainers.image.created={{.Date}}"
- "--label=org.opencontainers.image.name={{.ProjectName}}"
- "--label=org.opencontainers.image.revision={{.FullCommit}}"
- "--label=org.opencontainers.image.version={{.Version}}"
- "--label=org.opencontainers.image.source={{.GitURL}}"
- "--platform=linux/amd64"
- image_templates:
- "caffeinec/waku:{{ .Tag }}-arm64"
- "ghcr.io/caffeine-addictt/waku:{{ .Tag }}-arm64"
skip_push: false
dockerfile: Dockerfile.release
use: buildx
goarch: arm64
build_flag_templates:
- "--pull"
- "--label=io.artifacthub.package.readme-url=https://raw.githubusercontent.com/caffeine-addictt/waku/main/README.md"
- "--label=io.artifacthub.package.logo-url=https://waku.ngjx.org/static/logo.png"
- '--label=io.artifacthub.package.maintainers=[{"name":"Jun Xiang","email":"contact@ngjx.org"}]'
- "--label=io.artifacthub.package.license=AGPL-3.0"
- "--label=org.opencontainers.image.description=A simple template repository generator. Lets make starting new projects feel like a breeze again!"
- "--label=org.opencontainers.image.created={{.Date}}"
- "--label=org.opencontainers.image.name={{.ProjectName}}"
- "--label=org.opencontainers.image.revision={{.FullCommit}}"
- "--label=org.opencontainers.image.version={{.Version}}"
- "--label=org.opencontainers.image.source={{.GitURL}}"
- "--platform=linux/arm64"
docker_manifests:
- name_template: "caffeinec/waku:{{ .Tag }}"
image_templates:
- "caffeinec/waku:{{ .Tag }}-amd64"
- "caffeinec/waku:{{ .Tag }}-arm64"
- name_template: "ghcr.io/caffeine-addictt/waku:{{ .Tag }}"
image_templates:
- "ghcr.io/caffeine-addictt/waku:{{ .Tag }}-amd64"
- "ghcr.io/caffeine-addictt/waku:{{ .Tag }}-arm64"
- name_template: "{{ if not .Prerelease }}caffeinec/waku:latest{{ end }}"
image_templates:
- "caffeinec/waku:{{ .Tag }}-amd64"
- "caffeinec/waku:{{ .Tag }}-arm64"
- name_template: "{{ if not .Prerelease }}caffeinec/waku:v{{ .Major }}{{ end }}"
image_templates:
- "caffeinec/waku:{{ .Tag }}-amd64"
- "caffeinec/waku:{{ .Tag }}-arm64"
- name_template: "{{ if not .Prerelease }}ghcr.io/caffeine-addictt/waku:latest{{ end }}"
image_templates:
- "ghcr.io/caffeine-addictt/waku:{{ .Tag }}-amd64"
- "ghcr.io/caffeine-addictt/waku:{{ .Tag }}-arm64"
- name_template: "{{ if not .Prerelease }}ghcr.io/caffeine-addictt/waku:v{{ .Major }}{{ end }}"
image_templates:
- "ghcr.io/caffeine-addictt/waku:{{ .Tag }}-amd64"
- "ghcr.io/caffeine-addictt/waku:{{ .Tag }}-arm64"
nfpms:
- maintainer: Jun Xiang <contact@ngjx.org>
description: A simple template repository generator. Lets make starting new projects feel like a breeze again!
homepage: "https://github.com/caffeine-addictt/waku"
license: AGPL-3.0
formats: [rpm, apk, termux.deb, deb, archlinux]
dependencies: [git]
brews:
- homepage: "https://github.com/caffeine-addictt/waku"
license: "AGPL-3.0"
skip_upload: auto
directory: Formula/waku
repository:
owner: caffeine-addictt
name: homebrew-tap
branch: "waku"
token: "{{ .Env.GITHUB_PAT }}"
commit_author:
name: goreleaserbot
email: bot@goreleaser.com
commit_msg_template: "Brew formula update for {{ .ProjectName }} version {{ .Tag }}"
description: "A simple template repository generator. Lets make starting new projects feel like a breeze again!"
dependencies:
- git
test: |
system "#{bin}/waku version"
extra_install: |-
bash_completion.install "completions/waku.bash" => "waku"
zsh_completion.install "completions/waku.zsh" => "_waku"
fish_completion.install "completions/waku.fish"
man1.install "manpages/waku.1.gz"
# chocolateys:
# - name: waku
# title: Waku
# owners: caffeine-addictt
# authors: caffeine-addictt
# project_url: https://github.com/caffeine-addictt/waku
# package_source_url: https://github.com/caffeine-addictt/waku
# url_template: "https://github.com/caffeine-addictt/waku/releases/download/{{ .Tag }}/{{ .ArtifactName }}"
# icon_url: "https://waku.ngjx.org/static/logo.png"
# copyright: 2024 Jun Xiang
# license_url: https://github.com/caffeine-addictt/waku/blob/main/LICENSE
# require_license_acceptance: false
# docs_url: https://waku.ngjx.org
# bug_tracker_url: https://github.com/caffeine-addictt/waku/issues
# tags: "repository git generator simple quick quickstart template project project-generator cli command-line go"
# summary: "A simple template repository generator."
# description: A simple template repository generator. Lets make starting new projects feel like a breeze again!
# release_notes: "https://github.com/caffeine-addictt/waku/releases/tag/{{ .Tag }}"
# dependencies:
# - id: git
# api_key: "{{ .Env.CHOCOLATEY_API_KEY }}"
# source_repo: "https://push.chocolatey.org/"
# skip_publish: false
snapcrafts:
- name_template: "{{ .ProjectName }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}"
summary: Let's make starting new projects feel like a breeze again.
description: |
A simple template repository generator.
Lets make starting new projects feel like a breeze again!
license: AGPL-3.0
grade: stable
confinement: strict
publish: true
scoops:
- repository:
owner: caffeine-addictt
name: scoop-bucket
token: "{{ .Env.GITHUB_PAT }}"
skip_upload: auto
commit_author:
name: goreleaserbot
email: bot@goreleaser.com
commit_msg_template: "Brew formula update for {{ .ProjectName }} version {{ .Tag }}"
directory: bucket
homepage: https://github.com/caffeine-addictt/waku
description: A simple template repository generator. Lets make starting new projects feel like a breeze again!
license: AGPL-3.0
signs:
- cmd: cosign
certificate: "${artifact}.pem"
output: true
artifacts: checksum
args:
- sign-blob
- "--output-certificate=${certificate}"
- "--output-signature=${signature}"
- "${artifact}"
- --yes
docker_signs:
- cmd: cosign
artifacts: manifests
output: true
args:
- "sign"
- "${artifact}@${digest}"
- --yes
release:
ids: [default]
draft: false
replace_existing_draft: true
target_commitish: "{{ .Commit }}"
prerelease: auto
mode: replace
skip_upload: false
checksum:
name_template: "checksums.txt"
changelog:
use: github
sort: asc
abbrev: 0
filters:
exclude:
- "^(T|t)ypo"
groups:
- title: Features
regexp: '^.*?(F|f)eat(\(.+\))??!?:.+$'
order: 0
- title: Bug fixes
regexp: '^.*?(F|f)ix(\(.+\))??!?:.+$'
order: 1
- title: Improvements
regexp: '^.*?((D|d)ocs?|(S|s)tyle|(T|t)est|(B|b)uild|(P|p)erf|(R|r)efactor)(\(.+\))??!?:.+$'
order: 2
- title: Security issues
regexp: ^.*?(S|s)ecurity.*?$
order: 4
- title: Others
order: 999