forked from sunny0826/kubecm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.goreleaser.yml
66 lines (60 loc) · 1.84 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
# This is an example goreleaser.yaml file with some sane defaults.
# Make sure to check the documentation at http://goreleaser.com
builds:
- env:
- CGO_ENABLED=0
ldflags: -s -X github.com/sunny0826/kubecm/cmd.kubecmVersion={{.Version}} -X github.com/sunny0826/kubecm/cmd.gitCommit={{.Commit}} -X github.com/sunny0826/kubecm/cmd.buildDate={{.Date}}
goos:
- linux
- darwin
- windows
archives:
- replacements:
darwin: Darwin
linux: Linux
windows: Windows
386: i386
amd64: x86_64
checksum:
name_template: 'checksums.txt'
snapshot:
name_template: "{{ .Tag }}-SNAPSHOT-{{.ShortCommit}}"
changelog:
skip: false
sort: asc
release:
github:
owner: sunny0826
name: kubecm
name_template: '{{.ProjectName}}-v{{.Version}}'
brews:
- name: kubecm
tap:
owner: sunny0826
name: homebrew-tap
token: "{{ .Env.HOMEBREW_TOKEN }}"
url_template: "https://github.com/sunny0826/kubecm/releases/download/{{ .Tag }}/{{ .ArtifactName }}"
# Git author used to commit to the repository.
# Defaults are shown.
commit_author:
name: goreleaserbot
email: [email protected]
homepage: "https://github.com/sunny0826/kubecm"
description: "Merge multiple kubeconfig"
# Packages your package depends on.
dependencies:
- name: git
# So you can `brew test` your formula.
# Default is empty.
test: |
system "#{bin}/kubecm version"
# Custom install script for brew.
# Default is 'bin.install "program"'.
install: |
bin.install "kubecm"
# Install bash completion
output = Utils.safe_popen_read("#{bin}/kubecm", "completion", "bash")
(bash_completion/"kubecm").write output
# Install zsh completion
output = Utils.safe_popen_read("#{bin}/kubecm", "completion", "zsh")
(zsh_completion/"_kubecm").write output