Regenerated

This commit is contained in:
2026-03-19 14:45:02 +00:00
parent 265765341c
commit 70d5bc9fe2
29 changed files with 15 additions and 1392 deletions
+15 -21
View File
@@ -1042,7 +1042,7 @@ let
moduleName = "kitty";
username = config.defaultUser or "henrov";
# Assets path relative to this module
# Path to program assets (relative, self-contained)
assetPath = ../../../assets/system/conf/${moduleName};
# Read all files in the assets directory
@@ -1058,22 +1058,21 @@ in
# --- Declare the top-level toggle ---
options.enableKitty = lib.mkEnableOption "Enable Kitty terminal integration";
# --- Configuration applied only if enabled ---
# --- Only apply configuration if enabled ---
config = lib.mkIf enableProgram {
# Dendritic container for the program
myApps.${moduleName} = {
enable = true;
user = username;
assetsDir = assetPath;
files = files;
theme = "Catppuccin-Mocha";
};
# Kitty program configuration
programs.kitty.enable = true;
programs.kitty.extraConfig = ''
# 1) Theme first
include themes/Catppuccin-Mocha.conf
# 2) Force transparency last
#background_opacity 0.60
#dynamic_background_opacity yes
'';
# Deploy config files to the user's ~/.config directory
# Deploy configuration files to user's XDG config
home-manager.users.${username} = {
programs.kitty.enable = true;
xdg.configFile =
lib.mapAttrs' (name: value: {
name = "${moduleName}/${name}";
@@ -1081,7 +1080,7 @@ in
}) files;
};
# Optional: systemd service to sync / deploy configuration
# Example systemd service to sync assets to user's config directory
systemd.services."${moduleName}-sync" = {
description = "Sync ${moduleName} configuration";
wantedBy = [ "multi-user.target" ];
@@ -1095,7 +1094,6 @@ in
CONF="${assetPath}"
USER_HOME="/home/${username}"
# Copy all asset files into user's config directory
for f in ${lib.concatStringsSep " " (builtins.attrNames files)}; do
cp -u "$CONF/$f" "$USER_HOME/.config/${moduleName}/$f"
done
@@ -1104,12 +1102,8 @@ in
restartTriggers = [ assetPath ];
# Minimal PATH for the service
path = [
# Only include binaries if necessary
# pkgs.coreutils
# pkgs.gnugrep
];
# Minimal PATH (no pkgs references needed unless necessary)
path = [ ];
};
};
}