Package: readline-common Version: 8.1-2 Severity: wishlist
Hey. The default /etc/inputrc has: # mappings for Ctrl-left-arrow and Ctrl-right-arrow for word moving "\e[1;5C": forward-word "\e[1;5D": backward-word "\e[5C": forward-word "\e[5D": backward-word "\e\e[C": forward-word "\e\e[D": backward-word which moves forward/backward between words (which in that sense "are composed of alphanumeric characters (letters and digits)"). This is nice for any normal program using readline, but for bash in particular it would be IMO much more useful if it moves between shell tokens. Otherwise, the cursor stops at every / , - = etc. of which there are typically many in shell command lines. The following seem to provide just that: shell-forward-word Move forward to the end of the next word. Words are delimited by non-quoted shell metacharacters. shell-backward-word Move back to the start of the current or previous word. Words are delimited by non-quoted shell metacharacters. and you could made it *affect only bash* very easy: $if Bash "\e[1;5C": shell-forward-word "\e[1;5D": shell-backward-word $endif (Yes the name is "Bash" not "bash" here.) (Not sure why you need to map "\e[5C", "\e[5D", "\e\e[C" and "\e\e[D" as well. For me only "\e[1;5C" and "\e[1;5D" seems to be enough to get Ctrl-Left and Ctrl-Right. Thanks, Chris.