Dear Maintainer, after updating bash to version 5.1 ~ rc1-2 I noticed a new behavior: when you paste a text it is automatically selected. This however creates confusion as on plasma / konsole as the text is confused with the cursor (block), placed at the end of the word. How can I disable this new feature? Thank you, Antonio De Lorenzi
please could you forward that issue upstream, using the bashbug script? Thanks, Matthias
Hi, This seems to be related to this bash changelog entry: f. New active mark and face feature: when enabled, it will highlight the text inserted by a bracketed paste (the `active region') and the text found by incremental and non-incremental history searches. There's also this in CWRU/changes that seems related: - rl_activate_mark,rl_deactivate_mark,rl_mark_is_active_p, rl_keep_mark_active: new functions to manage an active region. We don't do anything with an active region yet. Part of a large patch for active regions from Daniel Colascione <dancol@google.com> originally back in 3/2018 Unfortunately it seems there is no way to not enable it. Might indeed be a good idea to ping upstream and/or Daniel Colascione about this.
Hi again, Chet answered that it can be disabled by disabling bracketed paste: https://lists.gnu.org/archive/html/bug-bash/2020-10/msg00082.html but I don't think that is a good option, so I'll try to persuade him to make this configurable separately.
I also found this feature causes confusing in some terminals. However disabling bracketed paste for BASH worked good enough for me: just adding 'bind "set enable-bracketed-paste off"' into /etc/bash.bashrc.
I just found another issue with this new BASH/Readline bug/feature. Even with 'bind "set enable-bracketed-paste off"', BASH 5.1 still behaving differently from previous versions: if pasted text contains new lines, BASH 5.1 would still buffering the pasted text, rather than evaluating the pasted text as commands immediately as I expected. This behavior is very annoying for me because I'm very used to repeat some commands quickly by copy-pasting them.
While adding 'enable-bracketed-paste off' into inputrc appears fixed this issue, no idea why it didn't fully work with bashrc only. 2021-01-14 20:59 GMT+08:00, 王昊然 <msl0000023508@gmail.com>: