You've already forked goreleaser
mirror of
https://github.com/goreleaser/goreleaser.git
synced 2025-07-13 01:30:50 +02:00
simplify brew formulae
This commit is contained in:
@ -18,7 +18,7 @@ import (
|
||||
const formulae = `class {{ .Name }} < Formula
|
||||
desc "{{ .Desc }}"
|
||||
homepage "{{ .Homepage }}"
|
||||
url "https://github.com/{{ .Repo }}/releases/download/{{ .Tag }}/{{ .BinaryName }}_#{%x(uname -s).gsub(/\n/, '')}_#{%x(uname -m).gsub(/\n/, '')}.tar.gz"
|
||||
url "https://github.com/{{ .Repo }}/releases/download/{{ .Tag }}/{{ .BinaryName }}_Darwin_x86_64.tar.gz"
|
||||
head "https://github.com/{{ .Repo }}.git"
|
||||
version "{{ .Tag }}"
|
||||
|
||||
|
@ -31,7 +31,7 @@ func assertDefaultTemplateData(t *testing.T, formulae string) {
|
||||
assert := assert.New(t)
|
||||
assert.Contains(formulae, "class Test < Formula")
|
||||
assert.Contains(formulae, "homepage \"https://google.com\"")
|
||||
assert.Contains(formulae, "url \"https://github.com/caarlos0/test/releases/download/v0.1.3/test_#{%x(uname -s).gsub(/\\n/, '')}_#{%x(uname -m).gsub(/\\n/, '')}.tar.gz\"")
|
||||
assert.Contains(formulae, "url \"https://github.com/caarlos0/test/releases/download/v0.1.3/test_Darwin_x86_64.tar.gz\"")
|
||||
assert.Contains(formulae, "head \"https://github.com/caarlos0/test.git\"")
|
||||
assert.Contains(formulae, "version \"v0.1.3\"")
|
||||
assert.Contains(formulae, "bin.install \"test\"")
|
||||
|
Reference in New Issue
Block a user