summaryrefslogtreecommitdiff
path: root/scripts/brightness-control
diff options
context:
space:
mode:
authorryukamish <[email protected]>2026-04-11 18:25:38 +0530
committerryukamish <[email protected]>2026-04-11 18:25:38 +0530
commitb3474e85dcce03e7de0b4a4e30ff7fad1f38ee26 (patch)
treebcfe42ad76a825c283eec653140ab4052f0b3017 /scripts/brightness-control
parent607891801fbf2051a0c9062d15a445dd238c1e1b (diff)
add: small bash scripts for added functionality
Diffstat (limited to 'scripts/brightness-control')
-rwxr-xr-xscripts/brightness-control18
1 files changed, 18 insertions, 0 deletions
diff --git a/scripts/brightness-control b/scripts/brightness-control
new file mode 100755
index 0000000..1c6b02c
--- /dev/null
+++ b/scripts/brightness-control
@@ -0,0 +1,18 @@
+#!/usr/bin/env bash
+
+# Taken from: https://github.com/salanpro/hyprland/tree/047f998e710b0ffe8d841a89fb7749b50c931b2c/.config/hypr/scripts
+
+# Brightness up and down
+if [[ "$1" == "up" ]]; then
+ brightnessctl set -e1 -n2 5%+ -m \
+ | awk -F ',' '{print $4+0}' \
+ | xargs -I[] notify-send -e -u low -h \
+ string:x-canonical-private-synchronous:brightness_notif -h \
+ int:value:[] "☀ Brightness: []%"
+elif [[ "$1" == "down" ]]; then
+ brightnessctl set -e1 -n2 5%- -m \
+ | awk -F ',' '{print $4+0}' \
+ | xargs -I[] notify-send -e -u low -h \
+ string:x-canonical-private-synchronous:brightness_notif -h \
+ int:value:[] "☀ Brightness: []%"
+fi