Include xone patches directly

This commit is contained in:
Manuel Thalmann 2024-05-09 10:17:52 +02:00
parent 230435088a
commit 06ac4b21da
2 changed files with 13 additions and 16 deletions

View file

@ -133,6 +133,14 @@
}); });
} }
) // { ) // {
overlays.default =
final: prev: {
linuxPackages_latest.xone = xonePatcher {
inherit (final) fetchFromGitHub;
inherit (final.linuxPackages_latest) xone;
};
};
nixosConfigurations = nixosConfigurations =
builtins.mapAttrs ( builtins.mapAttrs (
hostname: { system, config, modules }@machine: nixpkgs.lib.nixosSystem { hostname: { system, config, modules }@machine: nixpkgs.lib.nixosSystem {
@ -143,14 +151,16 @@
{ pkgs, ... }: { { pkgs, ... }: {
config = { config = {
_module.args = { _module.args = {
inherit xonePatcher;
machine = machine // { machine = machine // {
name = hostname; name = hostname;
config = (pkgs.callPackage config { }); config = (pkgs.callPackage config { });
}; };
}; };
nixpkgs.overlays = [
self.overlays.default
];
home-manager.sharedModules = [ home-manager.sharedModules = [
sops-nix.homeManagerModules.sops sops-nix.homeManagerModules.sops
]; ];

View file

@ -1,22 +1,9 @@
{ lib, pkgs, xonePatcher, ... }: { { lib, ... }: {
config = { config = {
nixpkgs = { nixpkgs = {
config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [
"xow_dongle-firmware" "xow_dongle-firmware"
]; ];
overlays = [
(final: prev: {
linuxPackages = prev.linuxPackages.extend (
final: prev: {
xone = xonePatcher {
inherit (pkgs) fetchFromGitHub;
inherit (prev) xone;
};
}
);
})
];
}; };
}; };
} }