horizon-gen-nix: Generate nix expressions from horizon-spec definitions

[ library, mit, nix, package-management, program ] [ Propose Tags ]

Generate nix expressions from horizon-spec definitions


[Skip to Readme]

Modules

  • Horizon
    • Gen
      • Horizon.Gen.Nix
        • Cabal2Nix
          • Horizon.Gen.Nix.Cabal2Nix.Options
        • Horizon.Gen.Nix.Options
        • Horizon.Gen.Nix.Pretty
        • Types
          • Horizon.Gen.Nix.Types.HorizonMode
        • Horizon.Gen.Nix.Writers

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

Versions [RSS] 0.2, 0.3.0, 0.3.0.1, 0.3.1.0, 0.4.0, 0.5, 0.6
Change log ChangeLog.md
Dependencies base (>=4.17 && <5), Cabal-syntax, cabal2nix, containers, dhall, directory, distribution-nixpkgs, either, horizon-gen-nix, horizon-spec (>=0.6 && <0.7), language-nix, lens, optparse-applicative, path, path-dhall-instance, pretty, silently, sydtest, text [details]
License MIT
Copyright 2022 Daniel Firth
Author Daniel Firth
Maintainer dan.firth@homotopic.tech
Category Package Management, Nix
Source repo head: git clone https://gitlab.homotopic.tech/horizon/horizon-gen-nix
Uploaded by locallycompact at 2023-02-04T14:12:07Z
Distributions
Executables horizon-gen-nix-tests, horizon-gen-nix
Downloads 319 total (17 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs not available [build log]
All reported builds failed as of 2023-02-04 [all 2 reports]

Readme for horizon-gen-nix-0.6

[back to package description]

horizon-gen-nix

horizon-gen-nix is an executable for generating nix expressions from horizon-spec dhall definitions.

Usage: horizon-gen-nix [--input-file INPUT_FILE]

Available options:
  -h,--help                Show this help text
  --input-file INPUT_FILE  The name of the input file.

Example input

The input file mentioned in the previous sections contains a dhall expression of the HorizonExport type (see horizon-spec).

Here is an example input file:

let H =
      https://gitlab.homotopic.tech/horizon/horizon-spec/-/raw/0.4.1/dhall/package.dhall
        sha256:9f2def711ea8796cdb24fa837da6681f9a7e752f87aeff08eee9b494c6e3374c

in  H.HorizonExport.MakeOverlay
      { packagesDir = "pkgs"
      , overlayFile = "overlay.nix"
      , overlay =
        [ H.callHackage "cabal2nix" "2.19.1"
        , H.callHackage "distribution-nixpkgs" "1.7.0.1"
        , H.callHackage "horizon-spec" "0.4.1"
        ]
      }

Building

nix build

Development

nix develop