diff options
| author | Don Williams <don.e.williams@gmail.com> | 2026-07-26 21:40:49 -0400 |
|---|---|---|
| committer | Pinapelz <yukais@pinapelz.com> | 2026-08-29 21:41:34 -0700 |
| commit | b725c587d285d99ab2a0b8514f9f976e1ec676fb (patch) | |
| tree | 4e51c09f250a47c6b2b0c321bcf2c790fe4fcdb6 /config/hypr/scripts | |
| parent | 2201cbc9248dfdf51e0c911071a50fbd60f24af0 (diff) | |
Added script for Hyprlang config to handle LidSwitch
Signed-off-by: Don Williams <don.e.williams@gmail.com>
On branch development
Your branch is up to date with 'origin/development'.
Changes to be committed:
modified: config/hypr/UserConfigs/Laptops.conf
new file: config/hypr/scripts/LidSwitch.sh
Diffstat (limited to 'config/hypr/scripts')
| -rwxr-xr-x | config/hypr/scripts/LidSwitch.sh | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/config/hypr/scripts/LidSwitch.sh b/config/hypr/scripts/LidSwitch.sh new file mode 100755 index 00000000..2a3fc3eb --- /dev/null +++ b/config/hypr/scripts/LidSwitch.sh @@ -0,0 +1,15 @@ +#!/usr/bin/env bash +# ================================================== +# KoolDots (2026) - Laptop Lid Switch Handler +# ================================================== + +ACTION="${1:-check}" +LOGFILE="/tmp/hypr_lid.log" + +echo "$(date '+%Y-%m-%d %H:%M:%S') - Lid event triggered: $ACTION" >> "$LOGFILE" + +if [ "$ACTION" = "close" ]; then + hyprctl keyword monitor "eDP-1, disable" >> "$LOGFILE" 2>&1 +elif [ "$ACTION" = "open" ]; then + hyprctl keyword monitor "eDP-1, preferred, auto, 1" >> "$LOGFILE" 2>&1 +fi |
