mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-05-19 11:30:22 -07:00
Provide a mechanism by which users can customize the nix devShell
This commit is contained in:
parent
ca25b36aa0
commit
f1ea1e533d
1
.gitignore
vendored
1
.gitignore
vendored
@ -27,3 +27,4 @@ tags
|
|||||||
|
|
||||||
stack.yaml.lock
|
stack.yaml.lock
|
||||||
|
|
||||||
|
flake.lock
|
||||||
|
11
flake.nix
11
flake.nix
@ -18,13 +18,18 @@
|
|||||||
};
|
};
|
||||||
overlays = xmonad.overlays ++ [ overlay ];
|
overlays = xmonad.overlays ++ [ overlay ];
|
||||||
in flake-utils.lib.eachDefaultSystem (system:
|
in flake-utils.lib.eachDefaultSystem (system:
|
||||||
let pkgs = import nixpkgs { inherit system overlays; };
|
let
|
||||||
|
pkgs = import nixpkgs { inherit system overlays; };
|
||||||
|
modifyDevShell =
|
||||||
|
if builtins.pathExists ./develop.nix
|
||||||
|
then import ./develop.nix
|
||||||
|
else _: x: x;
|
||||||
in
|
in
|
||||||
rec {
|
rec {
|
||||||
devShell = pkgs.haskellPackages.shellFor {
|
devShell = pkgs.haskellPackages.shellFor (modifyDevShell pkgs {
|
||||||
packages = p: [ p.xmonad-contrib ];
|
packages = p: [ p.xmonad-contrib ];
|
||||||
nativeBuildInputs = [ pkgs.cabal-install ];
|
nativeBuildInputs = [ pkgs.cabal-install ];
|
||||||
};
|
});
|
||||||
defaultPackage = pkgs.haskellPackages.xmonad-contrib;
|
defaultPackage = pkgs.haskellPackages.xmonad-contrib;
|
||||||
}) // { inherit overlay overlays; } ;
|
}) // { inherit overlay overlays; } ;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user