aboutsummaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
authorDon Williams <don.e.williams@gmail.com>2026-07-22 03:06:23 -0400
committerPinapelz <yukais@pinapelz.com>2026-08-29 21:40:35 -0700
commit0a0582f9add94373712ceebe9ead32cdc8160006 (patch)
tree7efe15341cca32d1668b88309d845d4628667836 /config
parent38ecce058e64ad6391fea9b60b5183a27b1c663a (diff)
Kitty theme duplicated entries
Signed-off-by: Don Williams <don.e.williams@gmail.com>
Diffstat (limited to 'config')
-rwxr-xr-xconfig/hypr/scripts/Kitty_themes.sh11
1 files changed, 4 insertions, 7 deletions
diff --git a/config/hypr/scripts/Kitty_themes.sh b/config/hypr/scripts/Kitty_themes.sh
index 7f34cbe6..c4baa729 100755
--- a/config/hypr/scripts/Kitty_themes.sh
+++ b/config/hypr/scripts/Kitty_themes.sh
@@ -107,14 +107,11 @@ apply_kitty_theme_to_config() {
local include_target
include_target="include ${XDG_CONFIG_HOME:-$HOME/.config}/kitty/kitty-themes/$(basename "$theme_file_path_to_apply")"
- if grep -q -E '^[#[:space:]]*include[[:space:]]+.*kitty-themes/.*\.conf' "$temp_kitty_config_file"; then
- sed -i -E "s|^[#[:space:]]*include[[:space:]]+.*kitty-themes/.*\.conf|$include_target|g" "$temp_kitty_config_file"
- else
- if [ -s "$temp_kitty_config_file" ] && [ "$(tail -c1 "$temp_kitty_config_file")" != "" ]; then
- echo >>"$temp_kitty_config_file"
- fi
- echo "$include_target" >>"$temp_kitty_config_file"
+ sed -i -E '/^[[:space:]]*include[[:space:]]+.*kitty-themes\/.*\.conf[[:space:]]*$/d' "$temp_kitty_config_file"
+ if [ -s "$temp_kitty_config_file" ] && [ "$(tail -c1 "$temp_kitty_config_file")" != "" ]; then
+ echo >>"$temp_kitty_config_file"
fi
+ echo "$include_target" >>"$temp_kitty_config_file"
cp "$temp_kitty_config_file" "$kitty_config"
rm "$temp_kitty_config_file"
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage