From 0ec6fc72a0cc81a53684b3a816c89e6511250a58 Mon Sep 17 00:00:00 2001 From: Damien Cassou Date: Sun, 26 Sep 2021 15:10:31 +0200 Subject: hledger-check-fancyassertions: init at 1.23 Co-authored-by: sterni --- .../hledger-check-fancyassertions/default.nix | 41 ++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 pkgs/applications/office/hledger-check-fancyassertions/default.nix (limited to 'pkgs/applications/office/hledger-check-fancyassertions') diff --git a/pkgs/applications/office/hledger-check-fancyassertions/default.nix b/pkgs/applications/office/hledger-check-fancyassertions/default.nix new file mode 100644 index 0000000000000..ed38bc29fa181 --- /dev/null +++ b/pkgs/applications/office/hledger-check-fancyassertions/default.nix @@ -0,0 +1,41 @@ +{lib, stdenvNoCC, haskellPackages, fetchurl, writers}: + +stdenvNoCC.mkDerivation rec { + pname = "hledger-check-fancyassertions"; + version = "1.23"; + + src = fetchurl { + url = "https://raw.githubusercontent.com/simonmichael/hledger/hledger-lib-${version}/bin/hledger-check-fancyassertions.hs"; + sha256 = "08p2din1j7l4c29ipn68k8vvs3ys004iy8a3zf318lzby4h04h0n"; + }; + + dontUnpack = true; + dontBuild = true; + + executable = writers.writeHaskell + "hledger-check-fancyassertions" + { + libraries = with haskellPackages; [ + base base-compat base-compat-batteries filepath hledger-lib_1_23 + megaparsec microlens optparse-applicative string-qq text time + transformers + ]; + inherit (haskellPackages) ghc; + } + src; + + installPhase = '' + runHook preInstall + install -D $executable $out/bin/${pname} + runHook postInstall + ''; + + meta = with lib; { + description = "Complex account balance assertions for hledger journals"; + homepage = "https://hledger.org/"; + changelog = "https://github.com/simonmichael/hledger/blob/master/CHANGES.md"; + license = licenses.gpl3; + maintainers = [ maintainers.DamienCassou ]; + platforms = lib.platforms.all; # GHC can cross-compile + }; +} -- cgit 1.4.1