move $path definition from apply-color* scripts to helper script

This commit is contained in:
2025-11-15 02:00:43 +01:00
parent 163cfda11e
commit 94be67bf43
16 changed files with 14 additions and 32 deletions

View File

@@ -1,6 +1,5 @@
#!/bin/bash
path=$(dirname "$(readlink -f "$0")")
[ -f "$HOME/.local/snippets/apply-color-helper" ] || {
echo "Missing helper script: $HOME/.local/snippets/apply-color-helper"
exit 1
@@ -12,4 +11,5 @@ kvantummanager --set catppuccin-mocha-"$colorName" || {
exit 1
}
log_success "kvantum"
log_success "kvantum"

View File

@@ -1,6 +1,5 @@
#!/bin/bash
path=$(dirname "$(readlink -f "$0")")
[ -f "$HOME/.local/snippets/apply-color-helper" ] || {
echo "Missing helper script: $HOME/.local/snippets/apply-color-helper"
exit 1
@@ -16,4 +15,5 @@ sed -i -E "s/^(gtk-theme=catppuccin-mocha-)[^-]+(-standard\+default)$/\1${colorN
nwg-look -a -x
log_success "nwg-look"
log_success "nwg-look"

View File

@@ -1,6 +1,5 @@
#!/bin/bash
path=$(dirname "$(readlink -f "$0")")
[ -f "$HOME/.local/snippets/apply-color-helper" ] || {
echo "Missing helper script: $HOME/.local/snippets/apply-color-helper"
exit 1
@@ -14,7 +13,7 @@ targetTypes=("os" "session" "status")
if ! python3 - "$file" "$colorHex" "${targetTypes[@]}"; then {
log_error "Failed to edit ${file}"
exit 1
} fi <<EOF
}; fi <<EOF
import json
import sys
@@ -61,4 +60,5 @@ if [ $? -ne 0 ]; then
exit 1
fi
log_success "oh-my-posh"
log_success "oh-my-posh"