Set everything under the chromium guard

This commit is contained in:
David Heinemeier Hansson
2025-08-31 13:08:40 +02:00
parent 80341b296e
commit fe20e89e0e

View File

@@ -1,7 +1,8 @@
echo "Switch to Omarchy Chromium for synchronized theme switching" echo "Switch to Omarchy Chromium for synchronized theme switching"
if omarchy-cmd-present chromium; then
set_theme_colors() { set_theme_colors() {
if [[ -f ~/.config/omarchy/current/theme/chromium.theme ]] && command -v chromium &>/dev/null; then if [[ -f ~/.config/omarchy/current/theme/chromium.theme ]]; then
chromium --no-startup-window --set-theme-color="$(<~/.config/omarchy/current/theme/chromium.theme)" chromium --no-startup-window --set-theme-color="$(<~/.config/omarchy/current/theme/chromium.theme)"
else else
# Use a default, neutral grey if theme doesn't have a color # Use a default, neutral grey if theme doesn't have a color
@@ -9,7 +10,6 @@ set_theme_colors() {
fi fi
} }
if omarchy-cmd-present chromium; then
omarchy-pkg-drop chromium omarchy-pkg-drop chromium
omarchy-pkg-add omarchy-chromium omarchy-pkg-add omarchy-chromium