2014-09-22 01:09:35 +00:00
|
|
|
require "formula"
|
2013-09-13 21:50:19 +00:00
|
|
|
|
|
|
|
class Htmlcleaner < Formula
|
2014-09-22 01:09:35 +00:00
|
|
|
homepage "http://htmlcleaner.sourceforge.net/index.php"
|
2015-01-02 01:08:33 +00:00
|
|
|
url "https://downloads.sourceforge.net/project/htmlcleaner/htmlcleaner/htmlcleaner%20v2.10/htmlcleaner-2.10.zip"
|
|
|
|
sha1 "dddeeece559b3834c2699f2dba72393de2b53186"
|
2013-09-13 21:50:19 +00:00
|
|
|
|
|
|
|
def install
|
|
|
|
libexec.install "htmlcleaner-#{version}.jar"
|
|
|
|
bin.write_jar_script libexec/"htmlcleaner-#{version}.jar", "htmlcleaner"
|
|
|
|
end
|
2014-02-04 21:37:20 +00:00
|
|
|
|
|
|
|
test do
|
|
|
|
path = testpath/"index.html"
|
|
|
|
path.write "<html>"
|
2014-05-04 19:12:41 +00:00
|
|
|
assert shell_output("#{bin}/htmlcleaner src=#{path}").include?("</html>")
|
2014-02-04 21:37:20 +00:00
|
|
|
end
|
2013-09-13 21:50:19 +00:00
|
|
|
end
|