about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/compilers/elm/packages/elm-format.nix
blob: 71386e00ef117358b35a8543bd80322d35c6ed28 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
{ mkDerivation, fetchgit, ansi-terminal, ansi-wl-pprint, array, base, binary
, bytestring, cmark, containers, directory, filepath, free, HUnit
, indents, json, mtl, optparse-applicative, parsec, process
, QuickCheck, quickcheck-io, split, lib, stdenv, tasty, tasty-golden
, tasty-hunit, tasty-quickcheck, text
}:
mkDerivation {
  pname = "elm-format";
  version = "0.8.4";
  src = fetchgit {
    url = "https://github.com/avh4/elm-format";
    sha256 = "0cxlhhdjx4h9g03z83pxv91qrysbi0ab92rl52jb0yvkaix989ai";
    rev = "5bd4fbe591fe8b456160c180cb875ef60bc57890";
  };
  postPatch = ''
    mkdir -p ./generated
    cat <<EOHS > ./generated/Build_elm_format.hs
    module Build_elm_format where

    gitDescribe :: String
    gitDescribe = "0.8.4"
    EOHS
  '';
  isLibrary = false;
  isExecutable = true;
  libraryHaskellDepends = [
    ansi-terminal ansi-wl-pprint array base binary bytestring
    containers directory filepath free indents json mtl
    optparse-applicative parsec process split text
  ];
  executableHaskellDepends = [ base ];
  testHaskellDepends = [
    base cmark containers HUnit mtl parsec QuickCheck quickcheck-io
    split tasty tasty-golden tasty-hunit tasty-quickcheck text
  ];
  doHaddock = false;
  homepage = "https://elm-lang.org";
  description = "A source code formatter for Elm";
  license = lib.licenses.bsd3;
}