From b86c2bad43120e68d4d2f770f622e030524c67f9 Mon Sep 17 00:00:00 2001 From: Bernardo Magri Date: Sat, 4 Apr 2026 10:13:12 +0100 Subject: [PATCH] feat(themes): implement declarative theme file management - Link active theme files from themes/ directly via Home Manager - Use 'recursive = true' to allow dynamic templating inside linked directories - Simplify nomarchy-theme-set to rely on declarative links - Update template generator to point to the unified theme directory --- bin/nomarchy-theme-set-templates | 2 +- modules/home/theme-files.nix | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 modules/home/theme-files.nix diff --git a/bin/nomarchy-theme-set-templates b/bin/nomarchy-theme-set-templates index d68c720..3fb9599 100755 --- a/bin/nomarchy-theme-set-templates +++ b/bin/nomarchy-theme-set-templates @@ -2,7 +2,7 @@ TEMPLATES_DIR="$OMARCHY_PATH/default/themed" USER_TEMPLATES_DIR="$HOME/.config/nomarchy/themed" -NEXT_THEME_DIR="$HOME/.config/nomarchy/current/next-theme" +NEXT_THEME_DIR="$HOME/.config/nomarchy/current/theme" COLORS_FILE="$NEXT_THEME_DIR/colors.toml" # Convert hex color to decimal RGB (e.g., "#1e1e2e" -> "30,30,46") diff --git a/modules/home/theme-files.nix b/modules/home/theme-files.nix new file mode 100644 index 0000000..58fce9e --- /dev/null +++ b/modules/home/theme-files.nix @@ -0,0 +1,10 @@ +{ config, ... }: + +{ + xdg.configFile."nomarchy/current/theme" = { + source = ../../themes/${config.nomarchy.theme}; + recursive = true; + }; + + xdg.configFile."nomarchy/current/theme.name".text = config.nomarchy.theme; +}