elmPackages.elm-format: 0.8.7 -> 0.8.8

This release officially supports GHC 9.6.

To avoid dependency conflicts with the elm compiler (see ansi-wl-pprint), elm-format is now built with GHC 9.8.

The GHC 9.4 elm package overrides have been removed.

Sander dd23e181 cdb6712f

Changed files
+67 -72
pkgs
+4 -4
pkgs/development/compilers/elm/default.nix
···
let
fetchElmDeps = pkgs.callPackage ./lib/fetchElmDeps.nix { };
# Haskell packages that require ghc 9.6
hs96Pkgs = import ./packages/ghc9_6 {
inherit
···
;
};
-
# Haskell packages that require ghc 9.4
-
hs94Pkgs = import ./packages/ghc9_4 { inherit pkgs lib; };
-
# Patched, originally npm-downloaded, packages
patchedNodePkgs = import ./packages/node {
inherit
···
assembleScope =
self: basics:
-
(hs96Pkgs self).elmPkgs // (hs94Pkgs self).elmPkgs // (patchedNodePkgs self) // basics;
in
lib.makeScope pkgs.newScope (
self:
···
let
fetchElmDeps = pkgs.callPackage ./lib/fetchElmDeps.nix { };
+
# Haskell packages that require ghc 9.8
+
hs98Pkgs = import ./packages/ghc9_8 { inherit pkgs lib; };
+
# Haskell packages that require ghc 9.6
hs96Pkgs = import ./packages/ghc9_6 {
inherit
···
;
};
# Patched, originally npm-downloaded, packages
patchedNodePkgs = import ./packages/node {
inherit
···
assembleScope =
self: basics:
+
(hs98Pkgs self).elmPkgs // (hs96Pkgs self).elmPkgs // (patchedNodePkgs self) // basics;
in
lib.makeScope pkgs.newScope (
self:
-53
pkgs/development/compilers/elm/packages/ghc9_4/default.nix
···
-
{ pkgs, lib }:
-
-
self:
-
pkgs.haskell.packages.ghc94.override {
-
overrides =
-
self: super:
-
let
-
inherit (pkgs.haskell.lib.compose) justStaticExecutables overrideCabal doJailbreak;
-
elmPkgs = {
-
/*
-
The elm-format expression is updated via a script in the https://github.com/avh4/elm-format repo:
-
`package/nix/build.sh`
-
*/
-
elm-format = justStaticExecutables (
-
overrideCabal (drv: {
-
jailbreak = true;
-
doHaddock = false;
-
postPatch = ''
-
mkdir -p ./generated
-
cat <<EOHS > ./generated/Build_elm_format.hs
-
module Build_elm_format where
-
gitDescribe :: String
-
gitDescribe = "${drv.version}"
-
EOHS
-
'';
-
-
description = "Formats Elm source code according to a standard set of rules based on the official Elm Style Guide";
-
homepage = "https://github.com/avh4/elm-format";
-
license = lib.licenses.bsd3;
-
maintainers = with lib.maintainers; [
-
avh4
-
turbomack
-
];
-
}) (self.callPackage ./elm-format/elm-format.nix { })
-
);
-
};
-
-
fixHaddock = overrideCabal (_: {
-
configureFlags = [ "--ghc-option=-Wno-error=unused-packages" ];
-
doHaddock = false;
-
});
-
in
-
elmPkgs
-
// {
-
inherit elmPkgs;
-
-
# Needed for elm-format
-
avh4-lib = fixHaddock (doJailbreak (self.callPackage ./elm-format/avh4-lib.nix { }));
-
elm-format-lib = fixHaddock (doJailbreak (self.callPackage ./elm-format/elm-format-lib.nix { }));
-
elm-format-test-lib = fixHaddock (self.callPackage ./elm-format/elm-format-test-lib.nix { });
-
elm-format-markdown = fixHaddock (self.callPackage ./elm-format/elm-format-markdown.nix { });
-
};
-
}
···
+3 -4
pkgs/development/compilers/elm/packages/ghc9_4/elm-format/avh4-lib.nix pkgs/development/compilers/elm/packages/ghc9_8/elm-format/avh4-lib.nix
···
relude,
tasty,
tasty-discover,
-
tasty-hspec,
tasty-hunit,
text,
}:
···
version = "0.0.0.1";
src = fetchgit {
url = "https://github.com/avh4/elm-format";
-
sha256 = "04l1bn4w8q3ifd6mc4mfrqxfbihmqnpfjdn6gr0x2jqcasjbk0bi";
-
rev = "b5cca4c26b473dab06e5d73b98148637e4770d45";
fetchSubmodules = true;
};
postUnpack = "sourceRoot+=/avh4-lib; echo source root reset to $sourceRoot";
···
process
relude
tasty
-
tasty-hspec
tasty-hunit
text
];
testToolDepends = [ tasty-discover ];
description = "Common code for haskell projects";
license = lib.licenses.bsd3;
}
···
relude,
tasty,
tasty-discover,
tasty-hunit,
text,
}:
···
version = "0.0.0.1";
src = fetchgit {
url = "https://github.com/avh4/elm-format";
+
sha256 = "13i1wgva6p9zsx1a7sfb3skc0rv187isb920chkhljyh48c12k8l";
+
rev = "d07fddc8c0eef412dba07be4ab8768d6abcca796";
fetchSubmodules = true;
};
postUnpack = "sourceRoot+=/avh4-lib; echo source root reset to $sourceRoot";
···
process
relude
tasty
tasty-hunit
text
];
testToolDepends = [ tasty-discover ];
+
doHaddock = false;
description = "Common code for haskell projects";
license = lib.licenses.bsd3;
}
+3 -2
pkgs/development/compilers/elm/packages/ghc9_4/elm-format/elm-format-lib.nix pkgs/development/compilers/elm/packages/ghc9_8/elm-format/elm-format-lib.nix
···
version = "0.0.0.1";
src = fetchgit {
url = "https://github.com/avh4/elm-format";
-
sha256 = "04l1bn4w8q3ifd6mc4mfrqxfbihmqnpfjdn6gr0x2jqcasjbk0bi";
-
rev = "b5cca4c26b473dab06e5d73b98148637e4770d45";
fetchSubmodules = true;
};
postUnpack = "sourceRoot+=/elm-format-lib; echo source root reset to $sourceRoot";
···
text
];
testToolDepends = [ tasty-discover ];
description = "Common code used by elm-format and elm-refactor";
license = lib.licenses.bsd3;
}
···
version = "0.0.0.1";
src = fetchgit {
url = "https://github.com/avh4/elm-format";
+
sha256 = "13i1wgva6p9zsx1a7sfb3skc0rv187isb920chkhljyh48c12k8l";
+
rev = "d07fddc8c0eef412dba07be4ab8768d6abcca796";
fetchSubmodules = true;
};
postUnpack = "sourceRoot+=/elm-format-lib; echo source root reset to $sourceRoot";
···
text
];
testToolDepends = [ tasty-discover ];
+
doHaddock = false;
description = "Common code used by elm-format and elm-refactor";
license = lib.licenses.bsd3;
}
+3 -2
pkgs/development/compilers/elm/packages/ghc9_4/elm-format/elm-format-markdown.nix pkgs/development/compilers/elm/packages/ghc9_8/elm-format/elm-format-markdown.nix
···
version = "0.0.0.1";
src = fetchgit {
url = "https://github.com/avh4/elm-format";
-
sha256 = "04l1bn4w8q3ifd6mc4mfrqxfbihmqnpfjdn6gr0x2jqcasjbk0bi";
-
rev = "b5cca4c26b473dab06e5d73b98148637e4770d45";
fetchSubmodules = true;
};
postUnpack = "sourceRoot+=/elm-format-markdown; echo source root reset to $sourceRoot";
···
mtl
text
];
description = "Markdown parsing for Elm documentation comments";
license = lib.licenses.bsd3;
}
···
version = "0.0.0.1";
src = fetchgit {
url = "https://github.com/avh4/elm-format";
+
sha256 = "13i1wgva6p9zsx1a7sfb3skc0rv187isb920chkhljyh48c12k8l";
+
rev = "d07fddc8c0eef412dba07be4ab8768d6abcca796";
fetchSubmodules = true;
};
postUnpack = "sourceRoot+=/elm-format-markdown; echo source root reset to $sourceRoot";
···
mtl
text
];
+
doHaddock = false;
description = "Markdown parsing for Elm documentation comments";
license = lib.licenses.bsd3;
}
+3 -2
pkgs/development/compilers/elm/packages/ghc9_4/elm-format/elm-format-test-lib.nix pkgs/development/compilers/elm/packages/ghc9_8/elm-format/elm-format-test-lib.nix
···
version = "0.0.0.1";
src = fetchgit {
url = "https://github.com/avh4/elm-format";
-
sha256 = "04l1bn4w8q3ifd6mc4mfrqxfbihmqnpfjdn6gr0x2jqcasjbk0bi";
-
rev = "b5cca4c26b473dab06e5d73b98148637e4770d45";
fetchSubmodules = true;
};
postUnpack = "sourceRoot+=/elm-format-test-lib; echo source root reset to $sourceRoot";
···
text
];
testToolDepends = [ tasty-discover ];
description = "Test helpers used by elm-format-tests and elm-refactor-tests";
license = lib.licenses.bsd3;
}
···
version = "0.0.0.1";
src = fetchgit {
url = "https://github.com/avh4/elm-format";
+
sha256 = "13i1wgva6p9zsx1a7sfb3skc0rv187isb920chkhljyh48c12k8l";
+
rev = "d07fddc8c0eef412dba07be4ab8768d6abcca796";
fetchSubmodules = true;
};
postUnpack = "sourceRoot+=/elm-format-test-lib; echo source root reset to $sourceRoot";
···
text
];
testToolDepends = [ tasty-discover ];
+
doHaddock = false;
description = "Test helpers used by elm-format-tests and elm-refactor-tests";
license = lib.licenses.bsd3;
}
+15 -5
pkgs/development/compilers/elm/packages/ghc9_4/elm-format/elm-format.nix pkgs/development/compilers/elm/packages/ghc9_8/elm-format/elm-format.nix
···
tasty-quickcheck,
text,
}:
-
mkDerivation {
pname = "elm-format";
-
version = "0.8.7";
src = fetchgit {
url = "https://github.com/avh4/elm-format";
-
sha256 = "04l1bn4w8q3ifd6mc4mfrqxfbihmqnpfjdn6gr0x2jqcasjbk0bi";
-
rev = "b5cca4c26b473dab06e5d73b98148637e4770d45";
fetchSubmodules = true;
};
isLibrary = false;
···
tasty-quickcheck
text
];
homepage = "https://elm-lang.org";
-
description = "Source code formatter for Elm";
license = lib.licenses.bsd3;
mainProgram = "elm-format";
}
···
tasty-quickcheck,
text,
}:
+
mkDerivation rec {
pname = "elm-format";
+
version = "0.8.8";
src = fetchgit {
url = "https://github.com/avh4/elm-format";
+
sha256 = "0klhnfvy1l6mck46qwk6pp4d66cvj0m5w91ylghdcr4fb6ka1gp0";
+
rev = "b06902f1e450f8be1e7b318caab7ccb1950893fa";
fetchSubmodules = true;
};
isLibrary = false;
···
tasty-quickcheck
text
];
+
doHaddock = false;
homepage = "https://elm-lang.org";
+
description = "A source code formatter for Elm";
license = lib.licenses.bsd3;
mainProgram = "elm-format";
+
postPatch = ''
+
mkdir -p ./generated
+
cat <<EOHS > ./generated/Build_elm_format.hs
+
module Build_elm_format where
+
+
gitDescribe :: String
+
gitDescribe = "${version}"
+
EOHS
+
'';
}
+36
pkgs/development/compilers/elm/packages/ghc9_8/default.nix
···
···
+
{ pkgs, lib }:
+
+
self:
+
pkgs.haskell.packages.ghc98.override {
+
overrides =
+
self: super:
+
let
+
inherit (pkgs.haskell.lib.compose) justStaticExecutables overrideCabal;
+
+
elmPkgs = {
+
/*
+
The elm-format expression is updated via a script in the https://github.com/avh4/elm-format repo:
+
`package/nix/build.sh`
+
*/
+
elm-format = justStaticExecutables (
+
overrideCabal (drv: {
+
homepage = "https://github.com/avh4/elm-format";
+
maintainers = with lib.maintainers; [
+
avh4
+
turbomack
+
];
+
}) (self.callPackage ./elm-format/elm-format.nix { })
+
);
+
};
+
in
+
elmPkgs
+
// {
+
inherit elmPkgs;
+
+
# Needed for elm-format
+
avh4-lib = self.callPackage ./elm-format/avh4-lib.nix { };
+
elm-format-lib = self.callPackage ./elm-format/elm-format-lib.nix { };
+
elm-format-test-lib = self.callPackage ./elm-format/elm-format-test-lib.nix { };
+
elm-format-markdown = self.callPackage ./elm-format/elm-format-markdown.nix { };
+
};
+
}