more tidying

This commit is contained in:
serenity-F 2026-09-02 15:10:17 +10:00
parent 4b2985f93b
commit 3e74692a79
No known key found for this signature in database
5 changed files with 14 additions and 77 deletions

View file

@ -1,54 +0,0 @@
{ self, inputs, ... }: {
# this module defines all hosts and allocates users to those hosts
flake.nixosConfigurations =
let
# users to include on machine
username = "serenity";
#username2 = "foobar";
# shorten paths
inherit (inputs.nixpkgs.lib) nixosSystem;
homeImports = import "${self}/home/profiles";
mod = "${self}/modules/system";
# get the basic config to build on top of
inherit (import mod) base;
# get these into the module system
specialArgs = { inherit inputs self; };
in
{
# declare hosts here
hades = nixosSystem {
inherit specialArgs;
modules = [
# specify host config directory
./hades
# users to include on machine
"${mod}/users/u-${username}.nix"
#"${mod}/users/u-${username2}.nix"
# home manager
"${mod}/misc/hm-parts.nix"
{
home-manager = {
# misc. hm settings
extraSpecialArgs = specialArgs;
backupFileExtension = ".hm-backup";
# user specific hm configurations present on machine
users.${username}.imports = homeImports."${username}";
#users.${username2}.imports = homeImports."${username2}";
};
}
];
};
}

View file

@ -1,9 +1,10 @@
{
self,
inputs,
config,
...
}:
{ self, inputs, config, ... }:
let
# default username here
username = "serenity";
{
# defines the hades specific config modules
@ -22,13 +23,13 @@
# extra modules
self.modules.nixos.gaming
# users to include on host
self.modules.nixos.serenity
# home manager and home manager imports
inputs.home-manager.nixosModules.home-manager
{
home-manager.backupFileExtension = "bak";
home-manager.users.serenity = {
imports = [
config.flake.homeModules.core-home
config.flake.homeModules.desktop
];
};

View file

@ -1,10 +0,0 @@
{ inputs, ... }:
{
# loads home manager modules
imports = [
inputs.home-manager.flakeModules.home-manager
];
}

View file

@ -4,7 +4,7 @@
let
# set your username here
name = "serenity";
username = "serenity";
# qol variable to make paths shorter
home = "/home/${name}";
@ -14,7 +14,7 @@ in
{
# user module declaration
flake.modules.nixos.${name} =
flake.modules.nixos.serenity =
{ pkgs, ... }:
@ -29,7 +29,7 @@ in
home-manager = {
# home-manager settings
backupFileExtension = "backup";
backupFileExtension = ".bak";
overwriteBackup = true;
verbose = true;
@ -38,7 +38,7 @@ in
useGlobalPkgs = true;
# hm user declaration
users.${name} = {
users.serenity = {
# user specific modules to import
imports = [
@ -54,7 +54,7 @@ in
];
# user declaration
users.users.${name} = {
users.users.serenity = {
# remember to change this
initialPassword = "password";