commit faa41d73290a53a5f796f7f04dc63d6c50b94f68
parent bc86a59650c4f7985da02dbc8b2d1cd7ceb51b9d
Author: Jared Tobin <jared@jtobin.io>
Date: Fri, 4 Oct 2024 18:10:42 +0400
nix: flake tweaks
* remove deprecated 'defaultPackage'; add packages.default.
* use haskellPackages's 'extend' instead of 'override'.
Diffstat:
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/flake.nix b/flake.nix
@@ -14,11 +14,9 @@
pkgs = import nixpkgs { inherit system; };
hlib = pkgs.haskell.lib;
- hpkgs = pkgs.haskell.packages.ghc964.override {
- overrides = new: old: {
- ${lib} = old.callCabal2nix lib ./. {};
- };
- };
+ hpkgs = pkgs.haskell.packages.ghc964.extend (new: old: {
+ ${lib} = old.callCabal2nix lib ./. {};
+ });
cc = pkgs.stdenv.cc;
ghc = hpkgs.ghc;
@@ -27,9 +25,7 @@
{
# cabal2nix disables haddock for packages with internal
# dependencies like secp256k1-sys, so enable it manually
- packages.${lib} = hlib.doHaddock hpkgs.${lib};
-
- defaultPackage = self.packages.${system}.${lib};
+ packages.default = hlib.doHaddock hpkgs.${lib};
devShells.default = hpkgs.shellFor {
packages = p: [