-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.goreleaser.yml
136 lines (130 loc) · 4.56 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
# Visit https://goreleaser.com for documentation on how to customize this
# behavior.
version: 2
before:
hooks:
# this is just an example and not a requirement for provider building/publishing
- go mod tidy
builds:
- env:
# goreleaser does not work with CGO, it could also complicate
# usage by users in CI/CD systems like HCP Terraform where
# they are unable to install libraries.
- CGO_ENABLED=0
mod_timestamp: "{{ .CommitTimestamp }}"
flags:
- -trimpath
ldflags:
- "-s -w -X main.version={{.Version}} -X main.commit={{.Commit}}"
goos:
- windows
- linux
- darwin
ignore:
- goos: darwin
goarch: "386"
binary: "{{ .ProjectName }}_v{{ .Version }}"
archives:
- format: zip
name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}"
checksum:
extra_files:
- glob: "terraform-registry-manifest.json"
name_template: "{{ .ProjectName }}_{{ .Version }}_manifest.json"
name_template: "{{ .ProjectName }}_{{ .Version }}_SHA256SUMS"
algorithm: sha256
signs:
- artifacts: checksum
args:
# if you are using this in a GitHub action or some other automated pipeline, you
# need to pass the batch flag to indicate its not interactive.
- "--batch"
- "--local-user"
- "{{ .Env.GPG_FINGERPRINT }}" # set this environment variable for your signing key
- "--output"
- "${signature}"
- "--detach-sign"
- "${artifact}"
release:
github:
owner: discue
name: terraform-provider-discue
extra_files:
- glob: "terraform-registry-manifest.json"
name_template: "{{ .ProjectName }}_{{ .Version }}_manifest.json"
# If you want to manually examine the release before its live, uncomment this line:
# draft: true
changelog:
# Set this to true if you don't want any changelog at all.
#
# Warning: this will also ignore any changelog files passed via `--release-notes`,
# and will render an empty changelog.
#
# This may result in an empty release notes on GitHub/GitLab/Gitea.
#
# Templates: allowed.
disable: false
# Changelog generation implementation to use.
#
# Valid options are:
# - `git`: uses `git log`;
# - `github`: uses the compare GitHub API, appending the author username to the changelog.
# - `gitlab`: uses the compare GitLab API, appending the author name and email to the changelog (requires a personal access token).
# - `gitea`: uses the compare Gitea API, appending the author username to the changelog.
# - `github-native`: uses the GitHub release notes generation API, disables the groups feature.
#
# Default: 'git'.
use: git
# Format to use for commit formatting.
# Only available when use is one of `github`, `gitea`, or `gitlab`.
#
# Default: '{{ .SHA }}: {{ .Message }} ({{ with .AuthorUsername }}@{{ . }}{{ else }}{{ .AuthorName }} <{{ .AuthorEmail }}>{{ end }})'.
# Extra template fields: `SHA`, `Message`, `AuthorName`, `AuthorEmail`, and
# `AuthorUsername`.
format: "{{.SHA}}: {{.Message}} (@{{.AuthorUsername}})"
# Sorts the changelog by the commit's messages.
# Could either be asc, desc or empty
# Empty means 'no sorting', it'll use the output of `git log` as is.
sort: asc
# Max commit hash length to use in the changelog.
#
# 0: use whatever the changelog implementation gives you
# -1: remove the commit hash from the changelog
# any other number: max length.
abbrev: -1
filters:
exclude:
- "^chore:(ci)"
- "^chore:(deps)"
- "^chore:(deps-dev)"
- "^docs:"
- "^style:"
- "^tests:"
- "^test:"
- "^Merge pull request"
- "^Merge branch"
- "^Revert "
# Group commits messages by given regex and title.
# Order value defines the order of the groups.
# Providing no regex means all commits will be grouped under the default group.
#
# Matches are performed against the first line of the commit message only,
# prefixed with the commit SHA1, usually in the form of
# `<abbrev-commit>[:] <title-commit>`.
# Groups are disabled when using github-native, as it already groups things by itself.
# Regex use RE2 syntax as defined here: https://github.com/google/re2/wiki/Syntax.
groups:
- title: Features
regexp: '^.*?feat(\([[:word:]]+\))??!?:.+$'
order: 0
- title: "Bug fixes"
regexp: '^.*?fix(\([[:word:]]+\))??!?:.+$'
order: 1
- title: "Chores"
regexp: '^.*?chore(\([[:word:]]+\))??!?:.+$'
order: 2
- title: "Refactorings"
regexp: '^.*?refactor(\([[:word:]]+\))??!?:.+$'
order: 3
- title: Others
order: 999