From 13964faa53b09924bdd27328311ba27457b0b61d Mon Sep 17 00:00:00 2001 From: Azat Bahawi Date: Wed, 16 Feb 2022 02:15:52 +0300 Subject: I hate the Antichrist --- scripts/toggle-trackpoint.sh | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'scripts/toggle-trackpoint.sh') diff --git a/scripts/toggle-trackpoint.sh b/scripts/toggle-trackpoint.sh index 1429dcf..d385553 100755 --- a/scripts/toggle-trackpoint.sh +++ b/scripts/toggle-trackpoint.sh @@ -3,9 +3,8 @@ ID=$(xinput list | grep -Eo 'TrackPoint\s*id\=[0-9]{1,2}' | grep -Eo '[0-9]{1,2}') STATE=$(xinput list-props "$ID" | awk '/Device Enabled/ {print $4}') -if [ "$STATE" = 1 ] -then - xinput disable "$ID" +if [ "$STATE" = 1 ]; then + xinput disable "$ID" else - xinput enable "$ID" + xinput enable "$ID" fi -- cgit 1.4.1