From fdf02bf9dfb3721ba8b5e07a1e509d4d92833d7a Mon Sep 17 00:00:00 2001 From: Linnnus Date: Tue, 3 Oct 2023 17:23:53 +0200 Subject: Seperate modules into general/personal --- flake.nix | 13 +++++++++---- modules/darwin/default.nix | 3 ++- modules/nixos/default.nix | 20 ++++++++++---------- 3 files changed, 21 insertions(+), 15 deletions(-) diff --git a/flake.nix b/flake.nix index a3859ce..f2a91aa 100644 --- a/flake.nix +++ b/flake.nix @@ -36,8 +36,12 @@ metadata = nixpkgs.lib.importTOML ./metadata.toml; }; - darwinModules = builtins.attrValues (import ./modules/darwin); - nixosModules = builtins.attrValues (import ./modules/nixos); + darwinModules = + builtins.attrValues (import ./modules/darwin).general + ++ builtins.attrValues (import ./modules/darwin).personal; + nixosModules = + builtins.attrValues (import ./modules/nixos).general + ++ builtins.attrValues (import ./modules/nixos).personal; # This is a function that generates an attribute by calling a function # you pass to it, with each system as an argument. `systems` lists all @@ -93,7 +97,8 @@ overlays = import ./overlays; - darwinModules = import ./modules/darwin; - nixosModules = import ./modules/nixos; + # We export the generally applicable modules. + darwinModules = (import ./modules/darwin).geneal; + nixosModules = (import ./modules/nixos).general; }; } diff --git a/modules/darwin/default.nix b/modules/darwin/default.nix index 832940f..48f0511 100644 --- a/modules/darwin/default.nix +++ b/modules/darwin/default.nix @@ -1,3 +1,4 @@ { - still-awake = import ./still-awake; + general.still-awake = import ./still-awake; + personal = {}; } diff --git a/modules/nixos/default.nix b/modules/nixos/default.nix index daea05f..3fcc34c 100644 --- a/modules/nixos/default.nix +++ b/modules/nixos/default.nix @@ -1,12 +1,12 @@ { - ## Reusable services. - - on-demand-minecraft = import ./on-demand-minecraft; - duksebot = import ./duksebot; - - ## Other miscellaneous configuration bits. These may be useful to other you. - - cloudflare-proxy = import ./cloudflare-proxy; - - disable-screen = import ./disable-screen; + # These components are + general = { + on-demand-minecraft = import ./on-demand-minecraft; + cloudflare-proxy = import ./cloudflare-proxy; + disable-screen = import ./disable-screen; + }; + + personal = { + duksebot = import ./duksebot; + }; } -- cgit v1.2.3