refactor: use inputs.self instead of rel. paths

This commit is contained in:
Swarsel 2024-12-05 02:36:25 +01:00
parent 83bc6af1f6
commit 33046cb4a3
Signed by: swarsel
GPG key ID: 26A54C31F2A4FD84
19 changed files with 1067 additions and 1711 deletions

View file

@ -1,6 +1,7 @@
{ lib, inputs, ... }:
_:
{
imports = [
./settings.nix
./xserver.nix
./users.nix
./env.nix
@ -38,35 +39,9 @@
./lid.nix
];
nix =
let
flakeInputs = lib.filterAttrs (_: lib.isType "flake") inputs;
in
{
settings = {
experimental-features = [
"nix-command"
"flakes"
"ca-derivations"
];
trusted-users = [ "swarsel" ];
flake-registry = "";
warn-dirty = false;
};
channel.enable = false;
registry = lib.mapAttrs (_: flake: { inherit flake; }) flakeInputs;
nixPath = lib.mapAttrsToList (n: _: "${n}=flake:${n}") flakeInputs;
};
nixpkgs.config.permittedInsecurePackages = [
"jitsi-meet-1.0.8043"
"electron-29.4.6"
];
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
};
system.stateVersion = lib.mkDefault "23.05";
}

View file

@ -226,7 +226,7 @@
proxy = { };
wifi = {
mode = "ap";
ssid = "Hotspot-fourside";
ssid = "Hotspot-swarsel";
};
wifi-security = {
group = "ccmp;";

View file

@ -9,4 +9,5 @@ _:
};
security.polkit.enable = true;
}

View file

@ -0,0 +1,31 @@
{ self, lib, inputs, ... }:
{
nix =
let
flakeInputs = lib.filterAttrs (_: lib.isType "flake") inputs;
in
{
settings = {
experimental-features = [
"nix-command"
"flakes"
"ca-derivations"
];
trusted-users = [ "swarsel" ];
flake-registry = "";
warn-dirty = false;
};
channel.enable = false;
registry = lib.mapAttrs (_: flake: { inherit flake; }) flakeInputs;
nixPath = lib.mapAttrsToList (n: _: "${n}=flake:${n}") flakeInputs;
};
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
extraSpecialArgs = inputs; # used mainly for inputs.self
};
system.stateVersion = lib.mkDefault "23.05";
}