jsonschema2pojo: depend on openjdk

master
Markus Reiter 2020-02-06 01:43:16 +01:00 committed by Alexander Bayandin
parent ead854db06
commit d891e3b2d2
1 changed files with 6 additions and 2 deletions

View File

@ -3,14 +3,18 @@ class Jsonschema2pojo < Formula
homepage "http://www.jsonschema2pojo.org/"
url "https://github.com/joelittlejohn/jsonschema2pojo/releases/download/jsonschema2pojo-1.0.2/jsonschema2pojo-1.0.2.tar.gz"
sha256 "158e927558e3ae4779dc2b7cd00e2010e43465af5a5aebdb55c889ccacb4d6e3"
revision 1
bottle :unneeded
depends_on :java => "1.6+"
depends_on "openjdk"
def install
libexec.install "jsonschema2pojo-#{version}-javadoc.jar", "lib"
bin.write_jar_script libexec/"lib/jsonschema2pojo-cli-#{version}.jar", "jsonschema2pojo"
(bin/"jsonschema2pojo").write <<~EOS
#!/bin/bash
exec "#{Formula["openjdk"].opt_bin}/java" -jar "#{libexec}/lib/jsonschema2pojo-cli-#{version}.jar" "$@"
EOS
end
test do