elmPackages: update and run the `update.sh` script

- Vendored the post-patch script for elm-format.
- Updated `update.sh` and committed the changes.

Sander e6ef81d4 dd23e181

Changed files
+19 -21
pkgs
development
compilers
elm
packages
ghc9_6
ansi-wl-pprint
elm
ghc9_8
+1 -1
pkgs/development/compilers/elm/packages/ghc9_6/ansi-wl-pprint/default.nix
···
base
];
homepage = "http://github.com/ekmett/ansi-wl-pprint";
-
description = "Wadler/Leijen Pretty Printer for colored ANSI terminal output";
+
description = "The Wadler/Leijen Pretty Printer for colored ANSI terminal output";
license = lib.licenses.bsd3;
}
+1 -1
pkgs/development/compilers/elm/packages/ghc9_6/elm/default.nix
···
zip-archive
];
homepage = "https://elm-lang.org";
-
description = "`elm` command line interface";
+
description = "The `elm` command line interface";
license = lib.licenses.bsd3;
mainProgram = "elm";
}
+11 -4
pkgs/development/compilers/elm/packages/ghc9_8/default.nix
···
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`
-
*/
+
# Post-patch override taken from the upstream repository:
+
# https://github.com/avh4/elm-format/blob/e7e5da37716acbfb4954a88128b5cc72b2c911d9/package/nix/generate_derivation.sh
elm-format = justStaticExecutables (
overrideCabal (drv: {
+
postPatch = ''
+
mkdir -p ./generated
+
cat <<EOHS > ./generated/Build_elm_format.hs
+
module Build_elm_format where
+
gitDescribe :: String
+
gitDescribe = "${drv.version}"
+
EOHS
+
'';
+
homepage = "https://github.com/avh4/elm-format";
maintainers = with lib.maintainers; [
avh4
+3 -12
pkgs/development/compilers/elm/packages/ghc9_8/elm-format/elm-format.nix
···
tasty-quickcheck,
text,
}:
-
mkDerivation rec {
+
mkDerivation {
pname = "elm-format";
version = "0.8.8";
src = fetchgit {
url = "https://github.com/avh4/elm-format";
-
sha256 = "0klhnfvy1l6mck46qwk6pp4d66cvj0m5w91ylghdcr4fb6ka1gp0";
-
rev = "b06902f1e450f8be1e7b318caab7ccb1950893fa";
+
sha256 = "13i1wgva6p9zsx1a7sfb3skc0rv187isb920chkhljyh48c12k8l";
+
rev = "d07fddc8c0eef412dba07be4ab8768d6abcca796";
fetchSubmodules = true;
};
isLibrary = false;
···
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
-
'';
}
+3 -3
pkgs/development/compilers/elm/update.sh
···
# Update all cabal packages.
for subpath in 'avh4-lib' 'elm-format-lib' 'elm-format-markdown' 'elm-format-test-lib'; do
-
cabal2nix 'https://github.com/avh4/elm-format' --revision '0.8.7' \
-
--subpath $subpath > packages/ghc9_2/elm-format/${subpath}.nix
+
cabal2nix --no-haddock 'https://github.com/avh4/elm-format' --revision '0.8.8' \
+
--subpath $subpath > packages/ghc9_8/elm-format/${subpath}.nix
done
-
cabal2nix 'https://github.com/avh4/elm-format' --revision '0.8.7' > packages/ghc9_2/elm-format/elm-format.nix
+
cabal2nix --no-haddock 'https://github.com/avh4/elm-format' --revision '0.8.8' > packages/ghc9_8/elm-format/elm-format.nix
cabal2nix 'https://github.com/ekmett/ansi-wl-pprint' --revision 'v0.6.8.1' > packages/ghc9_6/ansi-wl-pprint/default.nix
# We're building binaries from commit that npm installer is using since