-
Notifications
You must be signed in to change notification settings - Fork 4
/
.goreleaser.yaml
126 lines (117 loc) · 3.9 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
env:
- CGO_ENABLED=0
- GO111MODULE=on
snapshot:
name_template: "{{ .Version }}-next"
report_sizes: true
builds:
- main: ./cmd
goos:
- linux
- darwin
- windows
goarch:
- amd64
- arm64
ldflags:
- -s -w
- -X "github.com/starudream/go-lib/core/v2/config/version.gitVersion=v{{ .Version }}"
archives:
- format: tar.gz
name_template: "{{ .ProjectName }}_v{{ .Version }}_{{ .Os }}_{{ .Arch }}"
format_overrides:
- goos: windows
format: zip
dockers:
- goos: linux
goarch: amd64
dockerfile: Dockerfile
use: buildx
image_templates:
- "starudream/{{ .ProjectName }}:latest-amd64"
- "starudream/{{ .ProjectName }}:{{ .Tag }}-amd64"
- "ghcr.io/starudream/{{ .ProjectName }}:latest-amd64"
- "ghcr.io/starudream/{{ .ProjectName }}:{{ .Tag }}-amd64"
build_flag_templates:
- "--pull"
- "--platform=linux/amd64"
- "--label=org.opencontainers.image.created={{ .Date }}"
- "--label=org.opencontainers.image.title={{ .ProjectName }}"
- "--label=org.opencontainers.image.revision={{ .FullCommit }}"
- "--label=org.opencontainers.image.version={{ .Version }}"
- "--label=org.opencontainers.image.source={{ .GitURL }}"
- "--label=org.opencontainers.image.url={{ .GitURL }}"
- "--label=org.opencontainers.image.licenses=Apache-2.0"
- goos: linux
goarch: arm64
dockerfile: Dockerfile
use: buildx
image_templates:
- "starudream/{{ .ProjectName }}:latest-arm64"
- "starudream/{{ .ProjectName }}:{{ .Tag }}-arm64"
- "ghcr.io/starudream/{{ .ProjectName }}:latest-arm64"
- "ghcr.io/starudream/{{ .ProjectName }}:{{ .Tag }}-arm64"
build_flag_templates:
- "--pull"
- "--platform=linux/arm64"
- "--label=org.opencontainers.image.created={{ .Date }}"
- "--label=org.opencontainers.image.title={{ .ProjectName }}"
- "--label=org.opencontainers.image.revision={{ .FullCommit }}"
- "--label=org.opencontainers.image.version={{ .Version }}"
- "--label=org.opencontainers.image.source={{ .GitURL }}"
- "--label=org.opencontainers.image.url={{ .GitURL }}"
- "--label=org.opencontainers.image.licenses=Apache-2.0"
docker_manifests:
- name_template: "starudream/{{ .ProjectName }}:latest"
image_templates:
- "starudream/{{ .ProjectName }}:latest-amd64"
- "starudream/{{ .ProjectName }}:latest-arm64"
- name_template: "starudream/{{ .ProjectName }}:{{ .Tag }}"
image_templates:
- "starudream/{{ .ProjectName }}:{{ .Tag }}-amd64"
- "starudream/{{ .ProjectName }}:{{ .Tag }}-arm64"
- name_template: "ghcr.io/starudream/{{ .ProjectName }}:latest"
image_templates:
- "ghcr.io/starudream/{{ .ProjectName }}:latest-amd64"
- "ghcr.io/starudream/{{ .ProjectName }}:latest-arm64"
- name_template: "ghcr.io/starudream/{{ .ProjectName }}:{{ .Tag }}"
image_templates:
- "ghcr.io/starudream/{{ .ProjectName }}:{{ .Tag }}-amd64"
- "ghcr.io/starudream/{{ .ProjectName }}:{{ .Tag }}-arm64"
checksum:
name_template: "checksums.txt"
release:
target_commitish: "{{ .Commit }}"
changelog:
sort: asc
use: github
groups:
- title: Features
regexp: "^.*feat[(\\w)]*:+.*$"
order: 10
- title: Bug Fixes
regexp: "^.*fix[(\\w)]*:+.*$"
order: 20
- title: Performance Improvements
regexp: "^.*perf[(\\w)]*:+.*$"
order: 30
- title: Styles
regexp: "^.*style[(\\w)]*:+.*$"
order: 50
- title: Miscellaneous Chores
regexp: "^.*chore[(\\w)]*:+.*$"
order: 60
- title: Documentation
regexp: "^.*docs[(\\w)]*:+.*$"
order: 80
- title: Dependencies
regexp: "^.*deps[(\\w)]*:+.*$"
order: 85
- title: Build System
regexp: "^.*build[(\\w)]*:+.*$"
order: 90
- title: Continuous Integration
regexp: "^.*ci[(\\w)]*:+.*$"
order: 95
- title: Others
order: 99