Last active
September 27, 2017 05:28
-
-
Save keithballdotnet/aa56b0af04b4954402ebc4333e9e2993 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Plantuml < Formula | |
desc "Draw UML diagrams" | |
homepage "https://plantuml.com/" | |
url "https://downloads.sourceforge.net/project/plantuml/1.2017.16/plantuml.1.2017.16.jar" | |
sha256 "7a07d3f7cca5c0b38ca811984ef8da536da32932d68c1a6cce33ec2462b930bf" | |
version_scheme 1 | |
bottle :unneeded | |
depends_on "graphviz" | |
depends_on :java | |
def install | |
jar = "plantuml.jar" | |
libexec.install "plantuml.#{version}.jar" => jar | |
(bin/"plantuml").write <<-EOS.undent | |
#!/bin/bash | |
GRAPHVIZ_DOT="#{Formula["graphviz"].opt_bin}/dot" exec java -jar #{libexec}/#{jar} "$@" | |
EOS | |
chmod 0555, bin/"plantuml" | |
end | |
test do | |
system bin/"plantuml", "-testdot" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment