From a4623b8af966e9794cd95e885b41441ae7a75305 Mon Sep 17 00:00:00 2001 From: Anthony Rodriguez Date: Mon, 26 Aug 2024 13:46:52 +0200 Subject: [PATCH] move common imports to flake function --- flake.nix | 7 ++++++- hosts/solaire/default.nix | 5 ----- hosts/vamos/default.nix | 5 ----- 3 files changed, 6 insertions(+), 11 deletions(-) diff --git a/flake.nix b/flake.nix index 64eb086..2c7027b 100644 --- a/flake.nix +++ b/flake.nix @@ -30,6 +30,11 @@ system = "x86_64-linux"; commonModules = hostname: [ + ./modules/sops.nix + ./modules/system.nix + ./modules/gnome.nix + ./modules/syncthing + ./modules/stylix.nix ./hosts/${hostname} sops-nix.nixosModules.sops stylix.nixosModules.stylix @@ -43,7 +48,7 @@ { _module.args = { inherit hostname username; }; } ]; - configureSystem = hostname: homeConfig: nixpkgs.lib.nixosSystem { + configureSystem = hostname: homeConfig: nixpkgs.lib.nixosSystem { system = system; modules = commonModules hostname ++ [ { home-manager.users.${username} = import homeConfig; } diff --git a/hosts/solaire/default.nix b/hosts/solaire/default.nix index c513f4f..8223701 100644 --- a/hosts/solaire/default.nix +++ b/hosts/solaire/default.nix @@ -3,11 +3,6 @@ { imports = [ ./hardware-configuration.nix - ../../modules/sops.nix - ../../modules/system.nix - ../../modules/gnome.nix - ../../modules/syncthing - ../../modules/stylix.nix ]; services.xserver.videoDrivers = ["nvidia"]; diff --git a/hosts/vamos/default.nix b/hosts/vamos/default.nix index 168d66a..11220ef 100644 --- a/hosts/vamos/default.nix +++ b/hosts/vamos/default.nix @@ -3,11 +3,6 @@ { imports = [ ./hardware-configuration.nix - ../../modules/sops.nix - ../../modules/system.nix - ../../modules/gnome.nix - ../../modules/syncthing - ../../modules/stylix.nix ]; services.fprintd.enable = true;