Skip to content
Snippets Groups Projects
Commit 78c6d4a8 authored by Daniel Firth's avatar Daniel Firth
Browse files

dhall/package.dhall: import from horizon-platform

parent 41957033
Branches
Tags
No related merge requests found
let HsSrc =
< FromHackage : { name : Text, version : Text }
| FromGit :
{ url : Text, revision : Optional Text, subdir : Optional Text }
>
let Modifiers =
{ Type = { doJailbreak : Bool, doCheck : Bool }
, default = { doJailbreak = True, doCheck = False }
}
let Attr = λ(a : Type) → { mapKey : Text, mapValue : a }
let HsPkg =
{ Type = { source : HsSrc, modifiers : Modifiers.Type }
, default.modifiers = Modifiers.default
}
let callHackage
: ∀(name : Text) → ∀(version : Text) → Attr HsPkg.Type
= λ(name : Text) →
λ(version : Text) →
{ mapKey = name
, mapValue = HsPkg::{ source = HsSrc.FromHackage { name, version } }
}
let callCabal2nix
: ∀(name : Text) →
∀(url : Text) →
∀(revision : Optional Text) →
∀(subdir : Optional Text) →
Attr HsPkg.Type
= λ(name : Text) →
λ(url : Text) →
λ(revision : Optional Text) →
λ(subdir : Optional Text) →
{ mapKey = name
, mapValue = HsPkg::{ source = HsSrc.FromGit { url, revision, subdir } }
}
in { HsSrc, Modifiers, Attr, HsPkg, callHackage, callCabal2nix }
module Main ( main ) where
import Test.Tasty (TestTree, defaultMain, testGroup)
import Test.Tasty.Golden (goldenVsFile)
main :: IO ()
main = defaultMain tests
tests :: TestTree
tests = testGroup "Tests" [ test
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment