From 63251f87eb99347e4e2a8a76bedd57c8f1875a48 Mon Sep 17 00:00:00 2001 From: Bruno Carlin Date: Tue, 11 Feb 2025 15:23:05 +0100 Subject: [PATCH] feat: add darkman config --- darkman/.config/darkman/config.yaml | 4 ++++ darkman/.local/share/dark-mode.d/gtk-theme.sh | 5 +++++ darkman/.local/share/dark-mode.d/notification.sh | 6 ++++++ darkman/.local/share/light-mode.d/gtk-theme.sh | 5 +++++ darkman/.local/share/light-mode.d/notification.sh | 6 ++++++ 5 files changed, 26 insertions(+) create mode 100644 darkman/.config/darkman/config.yaml create mode 100755 darkman/.local/share/dark-mode.d/gtk-theme.sh create mode 100755 darkman/.local/share/dark-mode.d/notification.sh create mode 100755 darkman/.local/share/light-mode.d/gtk-theme.sh create mode 100755 darkman/.local/share/light-mode.d/notification.sh diff --git a/darkman/.config/darkman/config.yaml b/darkman/.config/darkman/config.yaml new file mode 100644 index 0000000..7733fdc --- /dev/null +++ b/darkman/.config/darkman/config.yaml @@ -0,0 +1,4 @@ +lat: 43.7 +lng: 7.2 +dbusserver: true +portal: true diff --git a/darkman/.local/share/dark-mode.d/gtk-theme.sh b/darkman/.local/share/dark-mode.d/gtk-theme.sh new file mode 100755 index 0000000..fbb8840 --- /dev/null +++ b/darkman/.local/share/dark-mode.d/gtk-theme.sh @@ -0,0 +1,5 @@ +#!/bin/sh + +gsettings set org.gnome.desktop.interface color-scheme prefer-dark +gsettings set org.gnome.desktop.interface gtk-theme Adwaita-dark + diff --git a/darkman/.local/share/dark-mode.d/notification.sh b/darkman/.local/share/dark-mode.d/notification.sh new file mode 100755 index 0000000..cfc386d --- /dev/null +++ b/darkman/.local/share/dark-mode.d/notification.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash + +# trigger a small, passive popup dialog to inform the user about darkman's activity +# reference https://wiki.archlinux.org/title/Desktop_notifications#Usage_in_programming + +notify-send --app-name="darkman" --urgency=low --icon=weather-clear-night "switching to dark mode" diff --git a/darkman/.local/share/light-mode.d/gtk-theme.sh b/darkman/.local/share/light-mode.d/gtk-theme.sh new file mode 100755 index 0000000..bdf4f63 --- /dev/null +++ b/darkman/.local/share/light-mode.d/gtk-theme.sh @@ -0,0 +1,5 @@ +#!/bin/sh + +gsettings set org.gnome.desktop.interface color-scheme prefer-light +gsettings set org.gnome.desktop.interface gtk-theme Adwaita + diff --git a/darkman/.local/share/light-mode.d/notification.sh b/darkman/.local/share/light-mode.d/notification.sh new file mode 100755 index 0000000..12ba061 --- /dev/null +++ b/darkman/.local/share/light-mode.d/notification.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash + +# trigger a small, passive popup dialog to inform the user about darkman's activity +# reference https://wiki.archlinux.org/title/Desktop_notifications#Usage_in_programming + +notify-send --app-name="darkman" --urgency=low --icon=weather-clear "switching to light mode"