Add homebrew recipe
ericfreese opened this issue · 2 comments
ericfreese commented
Base on consul
formula.
ericfreese commented
$ brew audit --new-formula rat
rat:
* GitHub repository not notable enough (<20 forks, <20 watchers and <50 stars)
* GitHub repository too new (<30 days old)
Error: 2 problems in 1 formula
Have to wait a little while for this...
In the mean time, should be able to manually save the formula below to
$(brew --prefix)/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/rat.rb
and run brew install rat
.
class Rat < Formula
desc "Compose shell commands to build terminal applications"
homepage "https://github.com/ericfreese/rat"
url "https://github.com/ericfreese/rat.git"
version "0.0.2"
sha256 "9da8d67a1e16056e3f05cdf536766e5571ede54a6c241c941d6c74eee5d64d31"
depends_on "go" => :build
def install
contents = Dir["{*,.git,.gitignore}"]
gopath = buildpath/"gopath"
(gopath/"src/github.com/ericfreese/rat").install contents
ENV["GOPATH"] = gopath
cd gopath/"src/github.com/ericfreese/rat" do
system "go", "build", "-o", "rat"
bin.install "rat"
end
end
test do
system "[", "-x", "#{bin}/rat", "]"
end
end
ericfreese commented
PR submitted: Homebrew/homebrew-core#19383