-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathtemplate.goreleaser.yaml
105 lines (89 loc) · 3.01 KB
/
template.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
# Documentation at https://goreleaser.com
# This file is a template and expressions such as __PROTOC_VERSION__ are replaced
# with environment variables such as $PROTOC_VERSION before usage.
# https://goreleaser.com/customization/build/
builds:
- binary: bin/protocurl
dir: src
env:
- CGO_ENABLED=0
goos:
- linux
- windows
- darwin
ignore:
# This combination is not pre-built by Google Protobuf
- goos: windows
goarch: arm64
# https://goreleaser.com/customization/archive/
archives:
- format: zip
files:
# NOTE: These files are listed again in the packages below. Keep them synced!
# binary is added implicitly
- README.md
- LICENSE.md
# copy protoc binaries and their .proto files previously downloaded
- src: 'release/tmp/protoc-__PROTO_VERSION__-{{ .Os }}-{{ .Arch }}/bin'
dst: 'protocurl-internal/bin'
strip_parent: true # avoids, that protoc is copied into protocurl-internal/bin/release/tmp/.../bin
- src: 'release/tmp/protoc-__PROTO_VERSION__-{{ .Os }}-{{ .Arch }}/include/google/protobuf'
dst: 'protocurl-internal/include/google/protobuf'
strip_parent: true
# Linux packages
nfpms:
- package_name: protocurl
description: |-
protoCURL is cURL for Protobuf:
The command-line tool for interacting with Protobuf over
HTTP REST endpoints using human-readable text formats.
homepage: https://github.com/qaware/protocurl
license: MIT
maintainer: GollyTicker <[email protected]>
priority: extra
formats:
- apk
- deb
dependencies:
- curl
suggests:
- curl
overrides:
# protoc is compiled against glibc whereas alpine uses musl.
# See: https://stackoverflow.com/a/64447927
apk:
dependencies:
- curl
- gcompat
# adds the ./bin/protocurl
bindir: /opt/protocurl
# GoReleaser will automatically add the binaries.
contents:
- src: /opt/protocurl/bin/protocurl
dst: /usr/bin/protocurl
type: "symlink"
# NOTE: These files are listed again in the archives above. Keep them synced!
# binary is added implicitly
- src: README.md
dst: /opt/protocurl/README.md
- src: LICENSE.md
dst: /opt/protocurl/LICENSE.md
# copy protoc binaries and their .proto files previously downloaded
- src: 'release/tmp/protoc-__PROTO_VERSION__-{{ .Os }}-{{ .Arch }}/bin'
dst: '/opt/protocurl/protocurl-internal/bin'
- src: 'release/tmp/protoc-__PROTO_VERSION__-{{ .Os }}-{{ .Arch }}/include/google/protobuf'
dst: '/opt/protocurl/protocurl-internal/include/google/protobuf'
release:
# If set to auto, will mark the release as not ready for production
# in case there is an indicator for this in the tag e.g. v1.0.0-rc1
prerelease: auto
checksum:
name_template: 'checksums.txt'
snapshot:
name_template: "{{ .Version }}-dev"
changelog:
sort: asc
filters:
exclude:
- '^docs:'
- '^test:'