summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheSiahxyz <164138827+TheSiahxyz@users.noreply.github.com>2025-06-17 12:05:36 +0900
committerTheSiahxyz <164138827+TheSiahxyz@users.noreply.github.com>2025-06-17 12:05:36 +0900
commit301d2bce6809d778ab8895b4ae2a5815c966d648 (patch)
tree1252ca9965942bffc88d1a65c3893e44da85110e
parentccf1c12d8f69c2b8ea02b122e0ee6e069c29ab50 (diff)
modified bin/extractkeys
-rwxr-xr-xar/.local/bin/extractkeys6
1 files changed, 3 insertions, 3 deletions
diff --git a/ar/.local/bin/extractkeys b/ar/.local/bin/extractkeys
index fadb830..5edf544 100755
--- a/ar/.local/bin/extractkeys
+++ b/ar/.local/bin/extractkeys
@@ -60,7 +60,7 @@ for file_path in "${config_files[@]}"; do
fi
if echo "$line" | grep -q "Keychord"; then
- line=$(echo "$line" | sed -e "s/&((Keychord){[0-9], {{\(.*\)}),/\1/g;s/^0/MEDIA/g;s/\([MEDIA|WIN|ALT|ULTRA|EXTRA|Shift|Control]\w\+\),\s\(.*\)}},\s\+\(\w\+\),\s\([^,]*\)/\1|\2|\3|\4/g;s/},{[0-9],//g;s/},{//g")
+ line=$(echo "$line" | sed -e "s/&((Keychord){[0-9], {{\(.*\)}),/\1/g;s/^0/MEDIA/g;s/\([MEDIA\|WIN\|ALT\|ULTRA\|EXTRA\|Shift\|Control]\w\+\),\s\(.*\)}},\s\+\(\w\+\),\s\([^,]*\)/\1|\2|\3|\4/g;s/},{0,//g;s/},{\(Shift\|Ctrl\),/\1/g;s/},{//g")
else
line=$(echo "$line" | sed -e "s/^{ \(.*\) },/\1/g;s/{ \([^, ]*\), \([^, ]*\), \([^, ]*\), \([^}]*\) }/\1 \2 \3 \4/g;s/,/|/g")
fi
@@ -70,7 +70,7 @@ for file_path in "${config_files[@]}"; do
s/ALTKEY/ALT/g;s/ALTMODALL/ALT+Ctrl+Shift/g;s/ALTMOD2/ALT+Ctrl/g;s/ALTMOD/ALT+Shift/g;
s/ULTRAKEY/WIN+ALT/g;s/ULTRAMODALL/WIN+ALT+Ctrl+Shift/g;s/ULTRAMOD2/WIN+ALT+Ctrl/g;s/ULTRAMOD/WIN+ALT+Shift/g;
s/EXTRAMOD/Ctrl+Shift/g;
- s/\([Shift|Control]\)Mask/\1/g;
+ s/\(Shift\|Control\)Mask/\1/g;
s/Control/Ctrl/g;
s/ //g;
s/XK_NO_MOD/NO_MOD/g;
@@ -82,7 +82,7 @@ for file_path in "${config_files[@]}"; do
s/\s*\(.*\)_R$/Right_\1/g;
s/\s*\(.*\)_L$/Left_\1/g;
s/MODKEY\(\d*\)/MOD\1/g;
- s/\([Shift|Control]\)Mask/\1/g;
+ s/\(Shift\|Control\)Mask[?,]/\<\1\>/g;
s/Control/Ctrl/g;
s/space/<space>/g;
s/BackSpace/<backspace>/g;