Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > gnu.bash.bug > #15712 > unrolled thread

bind -X shows inactive bindings (bindings removed using bind -r)

Started byŠimon Let <simon.a.let@gmail.com>
First post2019-12-12 10:57 +0100
Last post2019-12-12 10:57 +0100
Articles 1 — 1 participant

Back to article view | Back to gnu.bash.bug

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  bind -X shows inactive bindings (bindings removed using bind -r) Šimon Let <simon.a.let@gmail.com> - 2019-12-12 10:57 +0100

#15712 — bind -X shows inactive bindings (bindings removed using bind -r)

FromŠimon Let <simon.a.let@gmail.com>
Date2019-12-12 10:57 +0100
Subjectbind -X shows inactive bindings (bindings removed using bind -r)
Message-ID<mailman.718.1576144689.1979.bug-bash@gnu.org>
Hi,

according to `bind --help`, `bind -X` should "List key sequences bound with
-x and associated commands in a form that can be reused as input.".

However, when I remove a binding using `bind -r` it still shows up in the
list.

Reproduce:
1) Bind command using: `bind -x "\"\C-r\":\"echo I just pressed C-R\""`
Everything works as expected.
Pressing `\C-r` runs `echo I just pressed C-R`.
Running `bind -X` shows the following list of bound commands: `"\C-r":
"echo I just pressed C-R"`

2) Unbind command using `bind -r "\C-r"`
Pressing `\C-r` does nothing as expected.
Running `bind -X` still shows the same list of bound commands: `"\C-r":
"echo I just pressed C-R"`

This behavior seems very weird to me. I would expect the binding list to
match actual active bindings.

Affected bash versions: 4.3 - 5.0.11


Best regards,

Simon Let

[toc] | [standalone]


Back to top | Article view | gnu.bash.bug


csiph-web