1# yaml-language-server: $schema=https://goreleaser.com/static/schema-pro.json
2# vim: set ts=2 sw=2 tw=0 fo=jcroql
3version: 2
4
5project_name: crush
6
7includes:
8 - from_url:
9 url: charmbracelet/meta/main/notarize.yaml
10
11metadata:
12 mod_timestamp: "{{ .CommitTimestamp }}"
13 license: "MIT"
14 homepage: "https://charm.sh/crush"
15 description: "A powerful terminal-based AI assistant for developers, providing intelligent coding assistance directly in your terminal."
16 maintainers:
17 - "kujtimiihoxha <kujtim@charm.sh>"
18
19nightly:
20 publish_release: true
21 keep_single_release: true
22 version_template: "{{ incminor .Version }}-nightly"
23
24snapshot:
25 version_template: "0.0.0-{{ .Timestamp }}"
26
27before:
28 hooks:
29 - go mod tidy
30 - rm -rf completions
31 - mkdir completions
32 - rm -rf manpages
33 - mkdir manpages
34 - sh -c 'go run . completion bash >./completions/crush.bash'
35 - sh -c 'go run . completion zsh >./completions/crush.zsh'
36 - sh -c 'go run . completion fish >./completions/crush.fish'
37 - sh -c 'go run . man | gzip -c >./manpages/crush.1.gz'
38
39# gomod:
40# proxy: true
41
42builds:
43 - env:
44 - CGO_ENABLED=0
45 goos:
46 - linux
47 - darwin
48 - windows
49 - freebsd
50 # TODO: those fail to build
51 # - openbsd
52 # - netbsd
53 goarch:
54 - amd64
55 - arm64
56 - "386"
57 - arm
58 goarm:
59 - "7"
60
61 ldflags:
62 - -s -w -X github.com/charmbracelet/crush/internal/version.Version={{.Version}}
63
64archives:
65 - name_template: >-
66 crush_
67 {{- .Version }}_
68 {{- title .Os }}_
69 {{- if eq .Arch "amd64" }}x86_64
70 {{- else if eq .Arch "386" }}i386
71 {{- else }}{{ .Arch }}{{ end }}
72 {{- with .Arm}}v{{ . }}{{ end }}
73 wrap_in_directory: true
74 files:
75 - README*
76 - LICENSE*
77 - manpages/*
78 - completions/*
79 format_overrides:
80 - goos: windows
81 formats: [zip]
82
83checksum:
84 name_template: "checksums.txt"
85
86aurs:
87 - private_key: "{{ .Env.AUR_KEY }}"
88 git_url: "ssh://aur@aur.archlinux.org/crush-bin.git"
89 provides:
90 - crush
91 conflicts:
92 - crush
93 package: |-
94 cd "${srcdir}/crush_${pkgver}_Linux_${CARCH}"
95 # bin
96 install -Dm755 "./crush" "${pkgdir}/usr/bin/crush"
97 # license
98 mkdir -p "${pkgdir}/usr/share/licenses/crush/"
99 install -Dm644 ./LICENSE* "${pkgdir}/usr/share/licenses/crush/"
100 # completions
101 mkdir -p "${pkgdir}/usr/share/bash-completion/completions/"
102 mkdir -p "${pkgdir}/usr/share/zsh/site-functions/"
103 mkdir -p "${pkgdir}/usr/share/fish/vendor_completions.d/"
104 install -Dm644 "./completions/crush.bash" "${pkgdir}/usr/share/bash-completion/completions/crush"
105 install -Dm644 "./completions/crush.zsh" "${pkgdir}/usr/share/zsh/site-functions/_crush"
106 install -Dm644 "./completions/crush.fish" "${pkgdir}/usr/share/fish/vendor_completions.d/crush.fish"
107 # man pages
108 install -Dm644 "./manpages/crush.1.gz" "${pkgdir}/usr/share/man/man1/crush.1.gz"
109 # readme
110 mkdir -pv "${pkgdir}/usr/share/doc/crush/"
111 install -Dm644 README* "${pkgdir}/usr/share/doc/crush/"
112
113furies:
114 - disable: "{{ .IsNightly }}"
115 account: "{{ with .Env.FURY_TOKEN }}charmcli{{ else }}{{ end }}"
116 secret_name: FURY_TOKEN
117
118brews:
119 - repository:
120 owner: charmbracelet
121 name: homebrew-tap
122 token: "{{ .Env.HOMEBREW_TAP_GITHUB_TOKEN }}"
123 goarm: 7
124 extra_install: |-
125 bash_completion.install "completions/{{ .ProjectName }}.bash" => "{{ .ProjectName }}"
126 zsh_completion.install "completions/{{ .ProjectName }}.zsh" => "_{{ .ProjectName }}"
127 fish_completion.install "completions/{{ .ProjectName }}.fish"
128 man1.install "manpages/{{ .ProjectName }}.1.gz"
129
130npms:
131 - name: "@charmland/crush"
132 repository: "git+https://github.com/charmbracelet/crush.git"
133 bugs: https://github.com/charmbracelet/crush/issues
134 access: public
135
136nfpms:
137 - formats:
138 - apk
139 - deb
140 - rpm
141 - archlinux
142 file_name_template: "{{ .ConventionalFileName }}"
143 contents:
144 - src: ./completions/crush.bash
145 dst: /etc/bash_completion.d/crush
146 - src: ./completions/crush.fish
147 dst: /usr/share/fish/vendor_completions.d/crush.fish
148 - src: ./completions/crush.zsh
149 dst: /usr/share/zsh/site-functions/_crush
150 - src: ./manpages/crush.1.gz
151 dst: /usr/share/man/man1/crush.1.gz
152
153signs:
154 - cmd: cosign
155 certificate: "${artifact}.pem"
156 args:
157 - sign-blob
158 - "--output-certificate=${certificate}"
159 - "--output-signature=${signature}"
160 - "${artifact}"
161 - "--yes"
162 artifacts: checksum
163 output: true
164
165source:
166 enabled: true
167
168sboms:
169 - artifacts: archive
170 - id: source
171 artifacts: source
172
173nix:
174 - repository:
175 owner: "charmbracelet"
176 name: nur
177 token: "{{ .Env.HOMEBREW_TAP_GITHUB_TOKEN }}"
178 extra_install: |-
179 installManPage ./manpages/crush.1.gz.
180 installShellCompletion ./completions/*
181
182winget:
183 - publisher: charmbracelet
184 copyright: Charmbracelet, Inc
185 repository:
186 owner: "charmbracelet"
187 name: winget-pkgs
188 token: "{{ .Env.HOMEBREW_TAP_GITHUB_TOKEN }}"
189 branch: "crush-{{.Version}}"
190 pull_request:
191 enabled: true
192 draft: false
193 check_boxes: true
194 base:
195 owner: microsoft
196 name: winget-pkgs
197 branch: master
198
199changelog:
200 sort: asc
201 disable: "{{ .IsNightly }}"
202 filters:
203 exclude:
204 - "^(build|ci): "
205 - "^chore: auto-update generated files$"
206 - "^chore: docs$"
207 - "^chore: schema update$"
208 - "^chore: schema$"
209 - "^chore: typo$"
210 - "^chore: update schema$"
211 - "^chore: update$"
212 - "^chore\\(deps\\): "
213 - "^docs: update$"
214 - "^test:"
215 - "^test\\("
216 - "merge conflict"
217 - "merge conflict"
218 - Merge branch
219 - Merge pull request
220 - Merge remote-tracking branch
221 - go mod tidy
222 - "^wip "
223 - "^wip:"
224 groups:
225 - title: "New Features"
226 regexp: '^.*?feat(\(.+\))??!?:.+$'
227 order: 100
228 - title: "Security updates"
229 regexp: '^.*?sec(\(.+\))??!?:.+$'
230 order: 150
231 - title: "Bug fixes and improvements"
232 regexp: '^.*?(fix|refactor)(\(.+\))??!?:.+$'
233 order: 200
234 - title: "Documentation updates"
235 regexp: ^.*?docs?(\(.+\))??!?:.+$
236 order: 400
237 - title: Other work
238 order: 9999
239
240release:
241 prerelease: auto
242 footer:
243 from_url:
244 url: https://raw.githubusercontent.com/charmbracelet/meta/main/footer.md