From 9f7ff008e9069044d2335a06820a32b3f2bc0afd Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Fri, 6 Jan 2017 13:54:14 -0200 Subject: [PATCH] simplify brew formulae --- pipeline/brew/brew.go | 2 +- pipeline/brew/brew_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pipeline/brew/brew.go b/pipeline/brew/brew.go index 0160f2c29..05f66416f 100644 --- a/pipeline/brew/brew.go +++ b/pipeline/brew/brew.go @@ -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 }}" diff --git a/pipeline/brew/brew_test.go b/pipeline/brew/brew_test.go index 310cfa046..aab51441f 100644 --- a/pipeline/brew/brew_test.go +++ b/pipeline/brew/brew_test.go @@ -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\"")