mirror of
https://github.com/tw93/Mole.git
synced 2026-02-08 18:29:19 +00:00
esc to q
This commit is contained in:
@@ -296,7 +296,7 @@ read_key() {
|
||||
$'\x7f' | $'\x08') echo "DELETE" ;; # Backspace/Delete key
|
||||
$'\x1b')
|
||||
# ESC sequence - could be arrow key, delete key, or ESC alone
|
||||
# Read the next two bytes within 1s
|
||||
# Read the next bytes with 1s timeout for maximum compatibility
|
||||
if IFS= read -r -s -n 1 -t 1 rest 2> /dev/null; then
|
||||
if [[ "$rest" == "[" ]]; then
|
||||
# Got ESC [, read next character
|
||||
|
||||
Reference in New Issue
Block a user