From 3f37c38a08118fcc2c767065943709be0bce1829 Mon Sep 17 00:00:00 2001 From: Simon Rieger Date: Wed, 12 Jul 2023 23:18:47 +0200 Subject: [PATCH] modify brightness settings --- dot_config/waybar/config | 6 ++++-- dot_config/waybar/executable_brightness-down.sh | 3 ++- dot_config/waybar/executable_brightness-up.sh | 3 ++- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/dot_config/waybar/config b/dot_config/waybar/config index 96df4de..640044f 100644 --- a/dot_config/waybar/config +++ b/dot_config/waybar/config @@ -140,8 +140,10 @@ "backlight": { // "device": "acpi_video1", "format": "{percent}% {icon}", - "on-scroll-up": "~/.config/waybar/brightness-up.sh", - "on-scroll-down": "~/.config/waybar/brightness-down.sh", + "on-scroll-up": "~/.config/waybar/brightness-up.sh 1", + "on-scroll-down": "~/.config/waybar/brightness-down.sh 1", + "on-click": "~/.config/waybar/brightness-up.sh 5", + "on-click-right": "~/.config/waybar/brightness-down.sh 5", "format-icons": [ "", "", diff --git a/dot_config/waybar/executable_brightness-down.sh b/dot_config/waybar/executable_brightness-down.sh index d6bd7f1..611bd22 100644 --- a/dot_config/waybar/executable_brightness-down.sh +++ b/dot_config/waybar/executable_brightness-down.sh @@ -1 +1,2 @@ -brightnessctl set 1%- | sed -En 's/.*\(([0-9]+)%\).*/\1/p' > /tmp/wob +WERT=$1 +brightnessctl set ${WERT}%- | sed -En 's/.*\(([0-9]+)%\).*/\1/p' > /tmp/wob diff --git a/dot_config/waybar/executable_brightness-up.sh b/dot_config/waybar/executable_brightness-up.sh index 0a650ac..82b9787 100644 --- a/dot_config/waybar/executable_brightness-up.sh +++ b/dot_config/waybar/executable_brightness-up.sh @@ -1 +1,2 @@ -brightnessctl set +1% | sed -En 's/.*\(([0-9]+)%\).*/\1/p' > /tmp/wob +WERT=$1 +brightnessctl set +${WERT}% | sed -En 's/.*\(([0-9]+)%\).*/\1/p' > /tmp/wob