hyprland + waybar + GTK (Catpuccin)
This commit is contained in:
16
home-modules/theme/theme_oomox/scripts/is_dark.sh
Executable file
16
home-modules/theme/theme_oomox/scripts/is_dark.sh
Executable file
@@ -0,0 +1,16 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
script_dir="$(readlink -f "$(dirname "${0}")")"
|
||||
|
||||
is_dark() {
|
||||
hexinput=$(echo "${1}" | tr '[:lower:]' '[:upper:]')
|
||||
half_darker=$("${script_dir}/darker.sh" "${hexinput}" 88)
|
||||
if [[ "${half_darker}" = "000000" ]] ; then
|
||||
return 0;
|
||||
else
|
||||
return 1;
|
||||
fi
|
||||
}
|
||||
|
||||
is_dark "$@"
|
||||
Reference in New Issue
Block a user