Regenerated

This commit is contained in:
2026-03-20 14:22:52 +00:00
parent 7b7e41ccac
commit 9f0684599f
31 changed files with 29 additions and 1577 deletions
+17 -72
View File
@@ -327,39 +327,31 @@ in
* First the nix-files that flake really needs and that do not fit wel in the hierarchical structure
** =generated/hosts/traveldroid/traveldroid.nix=
#+BEGIN_SRC nix :tangle generated/hosts/traveldroid/traveldroid.nix :noweb tangle :mkdirp yes :eval never-html
{ config, lib, pkgs, inputs, ... }:
let
modulesPath = ./generated/modules;
# Import all modules via import-tree
# import-tree as before
importedModules = inputs.import-tree modulesPath;
allModules = builtins.attrValues importedModules.imports;
# --- Import module switches ---
moduleSwitches = import ./assets/system/modules.conf;
# Only keep enabled modules
enabledModules = lib.filterAttrs (_: mod: moduleSwitches[_] or false) allModules;
getFragment = module:
if builtins.hasAttr "homeManagerExtraUserFragment" module
then module.homeManagerExtraUserFragment
else {};
homeManagerExtraUserFragments = lib.foldl' lib.mkMerge {} (map getFragment allModules);
homeManagerExtraUserFragments = lib.foldl' lib.mkMerge {} (map getFragment enabledModules);
in
{
networking.hostName = "traveldroid";
system.stateVersion = "26.05";
# enableFlatpaks = false;
# enableThunar = false;
# enableWofi = false;
# enableZenBrowser= false;
# enableEmacs = false;
# enableKitty = false;
# enableZsh = false;
# enableFonts = false;
enableHyprland = true;
# enableStylix = false;
home-manager.users = lib.mkMerge [
(config.home-manager.users or {})
homeManagerExtraUserFragments
@@ -619,71 +611,20 @@ Setting up Hyprland
{ lib, config, ... }:
let
moduleName = "hyprland";
username = config.defaultUser or "henrov";
# Path to hyprland assets
assetPath = ../../../assets/hyprland/conf/hypr;
# Main config
mainConfigPath = "${assetPath}/hypr.hyprland.conf";
enableProgram = config.enableHyprland or false;
assetPath = ../../../assets/hyprland/conf/hypr;
mainConfigPath = "${assetPath}/hyprland.conf";
in
{
# --- Option ---
options.enableHyprland = lib.mkEnableOption "Enable Hyprland desktop";
# --- ExtraFragment for aggregator ---
{ lib, config, ... }:
let
moduleName = "hyprland";
username = config.defaultUser or "henrov";
# Path to hyprland assets
assetPath = ../../../assets/hyprland/conf/hypr;
# Main config
mainConfigPath = "${assetPath}/hypr.hyprland.conf";
enableProgram = config.enableHyprland or false;
in
{
# --- Option ---
options.enableHyprland = lib.mkEnableOption "Enable Hyprland desktop";
# --- ExtraFragment for aggregator ---
homeManagerExtraUserFragment = lib.mkIf enableProgram {
${username} = {
wayland.windowManager.hyprland = {
enable = true;
# Minimal example setting
settings.general."col.active_border" = lib.mkForce "0xff97cbcd 0xff89b4fa";
};
# Deploy the main config file
xdg.configFile = {
"hypr/hyprland.conf".text = builtins.readFile mainConfigPath;
};
};
};
} = lib.mkIf enableProgram {
${username} = {
home.stateVersion = "26.05";
home.username = username;
home.homeDirectory = "/home/${username}";
wayland.windowManager.hyprland = {
enable = true;
homeManagerExtraUserFragment = {
"${username}" = {
# Minimal example setting
settings.general."col.active_border" = lib.mkForce "0xff97cbcd 0xff89b4fa";
};
# Deploy the main config file
# Deploy the main Hyprland config file
xdg.configFile = {
"hypr/hyprland.conf".text = builtins.readFile mainConfigPath;
};
@@ -974,6 +915,10 @@ in
# --- Config ---
config = lib.mkIf enableProgram {
# Enable Hyprland in Wayland
wayland.windowManager.hyprland = {
enable = true;
# Enable XDG portals (required for Wayland apps)
xdg.portal.enable = true;