feat: Remove |> op from config to disable pipe-operator feature

This commit is contained in:
ulic-youthlic 2025-11-07 23:54:49 +08:00
parent b418f7ca4b
commit 0bdc1f142c
Signed by: youthlic
GPG key ID: 63E86C3C14A0D721
12 changed files with 167 additions and 121 deletions

View file

@ -9,13 +9,15 @@
{
config = {
environment.etc =
inputs
|> lib.mapAttrs' (
name: value:
lib.nameValuePair "nix/inputs/${name}" {
source = value;
}
);
with lib;
pipe inputs [
(mapAttrs' (
name: value:
lib.nameValuePair "nix/inputs/${name}" {
source = value;
}
))
];
nixpkgs = {
config = {
allowUnfree = true;
@ -72,9 +74,7 @@
experimental-features = [
"nix-command"
"flakes"
]
++ (lib.optional config.lix.enable "pipe-operator")
++ (lib.optional (!config.lix.enable) "pipe-operators");
];
warn-dirty = false;
system-features = [
"kvm"
@ -85,15 +85,17 @@
};
package = pkgs.nix;
registry =
inputs
|> lib.filterAttrs (name: _value: name != "nixpkgs")
|> lib.mapAttrs (
_name: value: {
flake = lib.mkForce {
outPath = value;
};
}
);
with lib;
pipe inputs [
(filterAttrs (name: _value: name != "nixpkgs"))
(mapAttrs (
_name: value: {
flake = lib.mkForce {
outPath = value;
};
}
))
];
};
};
}