2014-02-22 18:13:26 +00:00
|
|
|
|
require "formula"
|
|
|
|
|
|
|
|
|
|
class Aha < Formula
|
|
|
|
|
homepage "https://github.com/theZiz/aha"
|
2014-04-19 14:58:34 +00:00
|
|
|
|
url "https://github.com/theZiz/aha/archive/0.4.7.1.tar.gz"
|
|
|
|
|
sha1 "d428499b5e27bd514ca0ae6826a348b233534f59"
|
2014-02-22 18:13:26 +00:00
|
|
|
|
|
|
|
|
|
def install
|
|
|
|
|
system "make"
|
|
|
|
|
bin.install "aha"
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
test do
|
|
|
|
|
IO.popen("#{bin}/aha", "w+") do |pipe|
|
|
|
|
|
pipe.write("[35mrain[34mpill[00m")
|
|
|
|
|
pipe.close_write
|
|
|
|
|
assert_match /color:purple;">rain.*color:blue;">pill/, pipe.read
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
end
|