Refactor Home Manager modules

This commit is contained in:
Oliver Davies 2025-01-15 08:00:00 +00:00
parent 5229429bc4
commit 7771c88040
6 changed files with 22 additions and 29 deletions

View file

@ -62,6 +62,8 @@
nixosModules.default = ./nix/modules/nixos;
homeManagerModules.default = ./nix/modules/home-manager;
nixosConfigurations = {
lemp11 = nixpkgs.lib.nixosSystem {
specialArgs = specialArgs // {

View file

@ -0,0 +1,12 @@
{
outputs,
hostname,
username,
...
}:
{
imports = builtins.attrValues outputs.homeManagerModules ++ [
../../home/${username}/hosts/${hostname}.nix
];
}

View file

@ -44,7 +44,10 @@ let
};
in
{
imports = [ shared-config ];
imports = [
../common
shared-config
];
home.packages =
shared-packages
@ -64,6 +67,7 @@ in
);
home.sessionVariables = {
DOCUMENTS = "$HOME/Documents";
EDITOR = "nvim";
LANG = "en_GB.UTF-8";
LC_ALL = "en_GB.UTF-8";

View file

@ -1,12 +1,5 @@
{
config,
hostname,
inputs,
lib,
pkgs,
username,
self,
}:
{ lib, username, ... }:
{
home.username = "${username}";
home.homeDirectory = "/home/${username}";
@ -41,18 +34,4 @@
};
}
];
imports = [
(import ../../modules/home-manager {
inherit
config
inputs
lib
self
pkgs
;
})
../../home/${username}/hosts/${hostname}.nix
];
}

View file

@ -18,10 +18,7 @@
pkgs
;
})
./features/desktop
];
home.sessionVariables = {
DOCUMENTS = "$HOME/Documents";
};
}

View file

@ -1,4 +1,3 @@
Use nixosModules and homeManagerModules outputs in flake.nix to simplify importing modules
Add daily script
Add create-podcast-tasks script
Replace doppler with agenix