homebrew-core/Formula/docfx.rb

27 lines
675 B
Ruby

class Docfx < Formula
desc "Tools for building and publishing API documentation for .NET projects"
homepage "https://dotnet.github.io/docfx/"
url "https://github.com/dotnet/docfx/releases/download/v2.56.2/docfx.zip"
sha256 "1793370064de9bcc898953d77c9eb0ea62d1ed0d5e136d3c4ac30f4d7a90de64"
license "MIT"
bottle :unneeded
depends_on "mono"
def install
libexec.install Dir["*"]
(bin/"docfx").write <<~EOS
#!/bin/bash
mono #{libexec}/docfx.exe "$@"
EOS
end
test do
system bin/"docfx", "init", "-q"
assert_predicate testpath/"docfx_project/docfx.json", :exist?,
"Failed to generate project"
end
end