forked from cisco-open/fsoc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.goreleaser.yml
79 lines (77 loc) · 2.07 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
# GoRelease Build Configuration
# Refer https://goreleaser.com/customization/templates template variables.
# Refer https://goreleaser.com/customization/ for the fields.
project_name: fsoc
dist: builds
builds:
- id: fsoc-binaries
goos:
- darwin
- linux
- windows
goarch:
- amd64
- arm64
ignore:
- goos: windows
goarch: arm64
binary: fsoc-{{.Os}}-{{.Arch}}
no_unique_dist_dir: true
ldflags:
- -s
- -w
- -X {{ .Env.VERSION_PKG_PATH }}.defVersion={{ .Version }}
- -X {{ .Env.VERSION_PKG_PATH }}.defGitHash={{ .Env.GIT_HASH }}
- -X {{ .Env.VERSION_PKG_PATH }}.defGitBranch={{ .Env.GIT_BRANCH }}
- -X {{ .Env.VERSION_PKG_PATH }}.defBuildHost={{ .Env.BUILD_HOST }}
- -X {{ .Env.VERSION_PKG_PATH }}.defIsDev={{ .Env.BUILD_IS_DEV }}
- -X {{ .Env.VERSION_PKG_PATH }}.defGitDirty={{ .Env.GIT_DIRTY }}
- -X {{ .Env.VERSION_PKG_PATH }}.defGitTimestamp={{ .Env.GIT_TIMESTAMP }}
- -X {{ .Env.VERSION_PKG_PATH }}.defBuildTimestamp={{ .Env.BUILD_TIMESTAMP }}
flags:
- -trimpath
env:
- CGO_ENABLED=0
archives:
- id: fsoc-binary-archives
name_template: 'fsoc-{{ .Os }}-{{ .Arch }}'
format: binary
builds:
- fsoc-binaries
- id: fsoc-archives
name_template: 'fsoc-{{ .Os }}-{{ .Arch }}'
format: tar.gz
builds:
- fsoc-binaries
format_overrides:
- goos: windows
format: zip
brews:
- name: fsoc
ids:
- fsoc-archives
homepage: https://github.com/cisco-open/fsoc
description: "Cisco Observability Platform Developer's Control Tool"
license: "Apache-2.0"
commit_author:
name: cisco-service
email: 111539563+cisco-service@users.noreply.github.com
commit_msg_template: "Brew formula update for {{ .ProjectName }} version {{ .Tag }}"
folder: Formula
repository:
owner: cisco-open
name: homebrew-tap
branch: "{{ .ProjectName }}/{{ .Tag }}"
token: "{{ .Env.TAP_GITHUB_TOKEN }}"
pull_request:
enabled: true
base:
owner: cisco-open
name: homebrew-tap
branch: main
install: |
Dir.glob("fsoc-*-*") do |f|
bin.install f => "fsoc"
end
test: |
system "#{bin}/fsoc", "version"