-
Notifications
You must be signed in to change notification settings - Fork 9
/
.goreleaser.yaml
151 lines (139 loc) · 4.65 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
version: 2
before:
hooks:
- go mod tidy
builds:
- id: linux-builds
env:
- CGO_ENABLED=0
goos:
- linux
binary: "stackit"
- id: windows-builds
env:
- CGO_ENABLED=0
goos:
- windows
binary: "stackit"
- id: macos-builds
env:
- CGO_ENABLED=0
- BUNDLE_ID=cloud.stackit.cli
- "APPLE_APPLICATION_IDENTITY=Developer ID Application: Schwarz IT KG"
goos:
- darwin
binary: "stackit"
goarch:
- arm64
- amd64
hooks:
post:
- |
sh -c '
codesign -s "{{.Env.APPLE_APPLICATION_IDENTITY}}" -f -v --options=runtime "dist/macos-builds_{{.Target}}/{{.Name}}"
codesign -vvv --deep --strict "dist/macos-builds_{{.Target}}/{{.Name}}"
ls -l "dist/macos_{{.Target}}"
hdiutil create -volname "STACKIT-CLI" -srcfolder "dist/macos-builds_{{.Target}}/{{.Name}}" -ov -format UDZO "dist/{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}.dmg"
codesign -s "{{.Env.APPLE_APPLICATION_IDENTITY}}" -f -v --options=runtime "dist/{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}.dmg"
xcrun notarytool submit --keychain-profile "stackit-cli" --wait --progress dist/{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}.dmg
xcrun stapler staple "dist/{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}.dmg"
spctl -a -t open --context context:primary-signature -v dist/{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}.dmg
'
archives:
- format: tar.gz
format_overrides:
- goos: windows
format: zip
release:
# If set to auto, the GitHub release will be marked as "Pre-release"
# if the tag has a prerelease indicator (e.g. v0.0.1-alpha1)
prerelease: auto
changelog:
use: github
sort: asc
filters:
exclude:
- "^docs:"
- "^test:"
nfpms:
- id: linux-packages
# IDs of the builds for which to create packages for
builds:
- linux-builds
package_name: stackit
vendor: STACKIT
homepage: https://github.com/stackitcloud/stackit-cli
maintainer: STACKIT Developer Tools Team <[email protected]>
description: A command-line interface to manage STACKIT resources.
license: Apache 2.0
contents:
- src: LICENSE.md
dst: LICENSE.md
formats:
- deb
- rpm
signs:
- artifacts: package
args:
[
"-u",
"{{ .Env.GPG_FINGERPRINT }}",
"--output",
"${signature}",
"--detach-sign",
"${artifact}",
]
brews:
- name: stackit
repository:
owner: stackitcloud
name: homebrew-tap
commit_author:
name: CLI Release Bot
email: [email protected]
homepage: "https://github.com/stackitcloud/stackit-cli"
description: "A command-line interface to manage STACKIT resources.\nThis CLI is in a beta state. More services and functionality will be supported soon."
directory: Formula
license: "Apache-2.0"
# If set to auto, the release will not be uploaded to the homebrew tap repo
# if the tag has a prerelease indicator (e.g. v0.0.1-alpha1)
skip_upload: auto
snapcrafts:
# IDs of the builds for which to create packages for
- builds:
- linux-builds
# The name of the snap
name: stackit
# The canonical title of the application, displayed in the software
# centre graphical frontends
title: STACKIT CLI
summary: A command-line interface to manage STACKIT resources.
description: "A command-line interface to manage STACKIT resources.\nThis CLI is in a beta state. More services and functionality will be supported soon."
license: Apache-2.0
confinement: classic
# Grade "devel" will only release to `edge` and `beta` channels
# Grade "stable" will also release to the `candidate` and `stable` channels
grade: devel
# Whether to publish the Snap to the store
publish: true
winget:
- name: stackit
publisher: stackitcloud
short_description: A command-line interface to manage STACKIT resources.
license: Apache-2.0
publisher_support_url: "https://github.com/stackitcloud/stackit-cli/issues"
package_identifier: stackitcloud.stackit
homepage: "https://github.com/stackitcloud/stackit-cli"
# If set to auto, the release will not be uploaded to the homebrew tap repo
# if the tag has a prerelease indicator (e.g. v0.0.1-alpha1)
# Temporarily not skipping prereleases to test integration with Winget
# skip_upload: auto
repository:
owner: stackitcloud
name: winget-pkgs
pull_request:
enabled: true
base:
owner: microsoft
name: winget-pkgs
branch: master