forked from apricote/hcloud-upload-image
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.goreleaser.yaml
115 lines (98 loc) · 3.31 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
# yaml-language-server: $schema=https://goreleaser.com/static/schema.json
version: 2
before:
hooks:
- ./scripts/completions.sh
builds:
- env:
- CGO_ENABLED=0
goos:
- linux
- windows
- darwin
mod_timestamp: "{{ .CommitTimestamp }}"
flags:
- -trimpath
ldflags:
- -X {{ .ModulePath }}/internal/version.version={{ .Version }}
- -X {{ .ModulePath }}/internal/version.versionPrerelease=
archives:
- format: tar.gz
# this name template makes the OS and Arch compatible with the results of `uname`.
name_template: >-
{{ .ProjectName }}_
{{- title .Os }}_
{{- if eq .Arch "amd64" }}x86_64
{{- else if eq .Arch "386" }}i386
{{- else }}{{ .Arch }}{{ end }}
{{- if .Arm }}v{{ .Arm }}{{ end }}
# use zip for windows archives
format_overrides:
- goos: windows
format: zip
files:
- README.md
- LICENSE
- completions/*
nfpms:
- id: default
file_name_template: "{{ .ConventionalFileName }}"
package_name: hcloud-upload-image
vendor: Julian Tölle
homepage: https://github.com/apricote/hcloud-upload-image
maintainer: Julian Tölle <[email protected]>
formats:
- deb
- rpm
- apk
description: Manage custom OS images on Hetzner Cloud.
license: MIT
dependencies:
- openssh
recommends:
- hcloud-cli
contents:
- src: ./completions/hcloud-upload-image.bash
dst: /usr/share/bash-completion/completions/hcloud-upload-image
file_info:
mode: 0644
- src: ./completions/hcloud-upload-image.fish
dst: /usr/share/fish/vendor_completions.d/hcloud-upload-image.fish
file_info:
mode: 0644
- src: ./completions/hcloud-upload-image.zsh
dst: /usr/share/zsh/vendor-completions/_hcloud-upload-image
file_info:
mode: 0644
- src: ./LICENSE
dst: /usr/share/doc/hcloud-upload-image/license
file_info:
mode: 0644
aurs:
- name: hcloud-upload-image-bin
homepage: "https://github.com/apricote/hcloud-upload-image"
description: Manage custom OS images on Hetzner Cloud.
maintainers:
- "Julian Tölle <[email protected]>"
license: MIT
private_key: "{{ .Env.AUR_SSH_KEY }}"
git_url: "ssh://[email protected]/hcloud-upload-image-bin.git"
depends:
- openssh
package: |-
# bin
install -Dm755 "./hcloud-upload-image" "${pkgdir}/usr/bin/hcloud-upload-image"
# license
install -Dm644 "./LICENSE" "${pkgdir}/usr/share/licenses/hcloud-upload-image/LICENSE"
# completions
mkdir -p "${pkgdir}/usr/share/bash-completion/completions/"
mkdir -p "${pkgdir}/usr/share/zsh/site-functions/"
mkdir -p "${pkgdir}/usr/share/fish/vendor_completions.d/"
install -Dm644 "./completions/hcloud-upload-image.bash" "${pkgdir}/usr/share/bash-completion/completions/hcloud-upload-image"
install -Dm644 "./completions/hcloud-upload-image.zsh" "${pkgdir}/usr/share/zsh/site-functions/_hcloud-upload-image"
install -Dm644 "./completions/hcloud-upload-image.fish" "${pkgdir}/usr/share/fish/vendor_completions.d/hcloud-upload-image.fish"
snapshot:
name_template: "{{ .Version }}-dev+{{ .ShortCommit }}"
changelog:
# Generated by release-please
disable: true