aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKaz Kylheku <kazinator@Kazs-MacBook-Pro.local>2024-12-16 18:17:50 -0800
committerKaz Kylheku <kazinator@Kazs-MacBook-Pro.local>2024-12-16 18:17:50 -0800
commitef6868d2f3edc883b75c672bb17ece5bc6ef9c37 (patch)
tree601ab9c6da373ee4762d5c06ccaf77734371692f
parent7023efa48b48dfcd7e1c5cbe6f2310d44abb8efe (diff)
downloadbasta-ef6868d2f3edc883b75c672bb17ece5bc6ef9c37.tar.gz
basta-ef6868d2f3edc883b75c672bb17ece5bc6ef9c37.tar.bz2
basta-ef6868d2f3edc883b75c672bb17ece5bc6ef9c37.zip
workaround for GNU Readline problem.
- When the bracketed paste feature is enablied in GNU Readline, then each time the library processes a SIGLARM signal, it emits codes to turn off and on bracketed paste. In between these codes, it also emits a CR character that causes the cursor to jump to the beginning of the line. We work around this by turning off bracketed paste.
-rw-r--r--basta.sh4
1 files changed, 4 insertions, 0 deletions
diff --git a/basta.sh b/basta.sh
index 099c959..88e6496 100644
--- a/basta.sh
+++ b/basta.sh
@@ -179,6 +179,10 @@ if ! [ $basta_status_alarm_pid ] ; then
disown $!
fi
+# workaround for GNU Readline behavior whereby each time it
+# receives a SIGALRM, it emits cruft to the terminal.
+bind 'set enable-bracketed-paste 0'
+
# Copyright 2023
# Kaz Kylheku <kaz@kylheku.com>
# Vancouver, Canada