style: reorganizing

This commit is contained in:
punkfairie 2025-05-26 11:18:35 -07:00
parent 0d098f3823
commit 93ba9bfdaa
Signed by: punkfairie
GPG key ID: B3C5488E9A1A7CA6
21 changed files with 68 additions and 63 deletions

View file

@ -3,8 +3,11 @@
inputs.agenix.darwinModules.default
../base
./base
./home.nix
./stylix.nix
./system
./programs
];
}

View file

@ -1,7 +1,6 @@
{
imports = [
./home.nix
./homebrew.nix
./nix.nix
./stylix.nix
];
}

View file

@ -7,6 +7,7 @@
./home-manager.nix
./profile.nix
./system
./programs
];
}

View file

@ -0,0 +1,5 @@
{
imports = [
./session.nix
];
}

View file

@ -1,14 +0,0 @@
{
config,
inputs,
...
}: let
inherit (config.marleycfg.my) name;
in {
imports = [inputs.home-manager.nixosModules.home-manager];
config = {
home-manager.users."${name}" = {
home.homeDirectory = "/home/${name}";
};
};
}

View file

@ -1,42 +0,0 @@
{
lib,
config,
...
}: let
my = {
name = "marley";
username = "punkfairie";
fullName = "Marley Rae";
email = "marley@punkfairie.net";
};
desktopPass = "$y$j9T$ztWf9WeUCENC2T12qS4mi1$51ihV/5cQ8mdJJrNe7MMguk4hPB61S5xHawsfi.1hL3";
serverPass = "$y$j9T$8hA7OWZsdQMHqYIy8LkYQ1$hFeP2ak3QA4FtoIYIwqPg10//ZOSZrAw1PzJj0PuGSA";
in {
marleycfg.my = {
inherit (my) name username fullName email;
};
users = {
mutableUsers = false;
groups = {
"compat" = {
gid = 1000;
};
};
users."${my.name}" = {
isNormalUser = true;
description = my.fullName;
extraGroups =
["wheel" "compat"]
++ (lib.optional config.networking.networkmanager.enable "networkmanager")
++ (lib.optional config.virtualisation.docker.enable "docker");
hashedPassword =
if config.marleycfg.profiles.server
then serverPass
else desktopPass;
};
};
}

View file

@ -6,8 +6,11 @@
./base
./hardware
./system
./shell
./users.nix
./programs
./services

View file

@ -1,5 +1,8 @@
{
imports = [
./stylix.nix
./fonts.nix
./hyprlock.nix
./ly.nix
./niri.nix

View file

@ -1,12 +1,8 @@
{
imports = [
./boot.nix
./fonts.nix
./home.nix
./i18n.nix
./networking.nix
./nix.nix
./stylix.nix
./users.nix
];
}

51
modules/nixos/users.nix Normal file
View file

@ -0,0 +1,51 @@
{
inputs,
lib,
config,
...
}: let
my = {
name = "marley";
username = "punkfairie";
fullName = "Marley Rae";
email = "marley@punkfairie.net";
};
desktopPass = "$y$j9T$ztWf9WeUCENC2T12qS4mi1$51ihV/5cQ8mdJJrNe7MMguk4hPB61S5xHawsfi.1hL3";
serverPass = "$y$j9T$8hA7OWZsdQMHqYIy8LkYQ1$hFeP2ak3QA4FtoIYIwqPg10//ZOSZrAw1PzJj0PuGSA";
in {
imports = [inputs.home-manager.nixosModules.home-manager];
config = {
marleycfg.my = {
inherit (my) name username fullName email;
};
users = {
mutableUsers = false;
groups = {
"compat" = {
gid = 1000;
};
};
users."${my.name}" = {
isNormalUser = true;
description = my.fullName;
extraGroups =
["wheel" "compat"]
++ (lib.optional config.networking.networkmanager.enable "networkmanager")
++ (lib.optional config.virtualisation.docker.enable "docker");
hashedPassword =
if config.marleycfg.profiles.server
then serverPass
else desktopPass;
};
};
home-manager.users."${my.name}" = {
home.homeDirectory = "/home/${my.name}";
};
};
}