dhall 1.20.0 (new formula)

Closes #34157.

Signed-off-by: Igor Kapkov <igasgeek@me.com>
This commit is contained in:
Devon Stewart 2018-11-15 22:23:14 -08:00 committed by Igor Kapkov
parent 2eb865799d
commit f701081bbe
No known key found for this signature in database
GPG key ID: D7EEA6CEB7ECBDC7

23
Formula/dhall.rb Normal file
View file

@ -0,0 +1,23 @@
require "language/haskell"
class Dhall < Formula
include Language::Haskell::Cabal
desc "Interpreter for the Dhall language"
homepage "https://dhall-lang.org/"
url "https://hackage.haskell.org/package/dhall-1.20.0/dhall-1.20.0.tar.gz"
sha256 "662862e65e73de18c01001e0ab43af155d111631ad12d14d89ec37d1397ccf43"
depends_on "cabal-install" => :build
depends_on "ghc" => :build
def install
install_cabal_package
end
test do
assert_match "{=}", pipe_output("#{bin}/dhall format", "{ = }", 0)
assert_match "8", pipe_output("#{bin}/dhall normalize", "(\\(x : Natural) -> x + 3) 5", 0)
assert_match "∀(x : Natural) → Natural", pipe_output("#{bin}/dhall type", "\\(x: Natural) -> x + 3", 0)
end
end