fix(nix): nixPath handle linux/darwin diff
This commit is contained in:
parent
fe438a67d7
commit
e7f8ccd4ba
1 changed files with 11 additions and 3 deletions
|
@ -5,6 +5,7 @@
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
inherit (lib) filterAttrs;
|
inherit (lib) filterAttrs;
|
||||||
|
inherit (pkgs.stdenv) isDarwin isLinux;
|
||||||
flakes = filterAttrs (name: value: value ? outputs) inputs;
|
flakes = filterAttrs (name: value: value ? outputs) inputs;
|
||||||
in {
|
in {
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
@ -24,8 +25,15 @@ in {
|
||||||
builtins.mapAttrs
|
builtins.mapAttrs
|
||||||
(name: v: {flake = v;})
|
(name: v: {flake = v;})
|
||||||
flakes;
|
flakes;
|
||||||
nixPath = [
|
nixPath =
|
||||||
{nixpkgs = "${inputs.nixpkgs.outPath}";}
|
if isDarwin
|
||||||
];
|
then [
|
||||||
|
{nixpkgs = "${inputs.nixpkgs.outPath}";}
|
||||||
|
]
|
||||||
|
else if isLinux
|
||||||
|
then [
|
||||||
|
"nixpkgs=${inputs.nixpkgs.outPath}"
|
||||||
|
]
|
||||||
|
else [];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue