homebrew-core/Formula/base64.rb

24 lines
567 B
Ruby
Raw Normal View History

2009-10-25 12:14:22 +00:00
require 'formula'
2011-03-10 05:11:03 +00:00
class Base64 < Formula
2009-10-25 12:14:22 +00:00
homepage 'http://www.fourmilab.ch/webtools/base64/'
2013-01-27 01:46:24 +00:00
url 'http://www.fourmilab.ch/webtools/base64/base64-1.5.tar.gz'
sha1 '25b5ae71c2818c7a489065ca1637806cd5109524'
2009-10-25 12:14:22 +00:00
def install
system "./configure", "--disable-debug", "--disable-dependency-tracking"
2009-10-25 12:14:22 +00:00
system "make"
bin.install "base64"
man1.install "base64.1"
2009-10-25 12:14:22 +00:00
end
test do
path = testpath/"a.txt"
path.write "hello"
output = `#{bin}/base64 #{path}`.strip
assert_equal "aGVsbG8=", output
assert_equal 0, $?.exitstatus
end
2009-10-25 12:14:22 +00:00
end