When i type Ctrl+Left or Ctrl+Right within Guake or gnome-terminal the last one's behaviour turns to a some kind of non-usual mode: - key acts like arrow up and + like arrow down, v runs Nano, etc. How can i disable this feature ?

UPD: my friend told me that's X.org hotkeys... How can i disable 'em? Googling does not help at all...

UPD2: here's a video showing what's going on.

  • 2
    Probably something with your settings. I don't have that behavior, neither for guake nor gnome-terminal.
    – phunehehe
    Jul 27, 2011 at 15:18
  • 2
    Sounds pretty much like how emacs/vi work... completely intuitive. :-)
    – user541686
    Jul 27, 2011 at 15:31
  • 3
    Does this happen in another account with your distribution's default settings? If you press Ctrl+V then Ctrl+Left at a shell prompt, does this insert characters (if so, which) or not? Jul 27, 2011 at 16:02
  • Ctrl+v and then Ctrl+left inserts ^[[1;5C.
    – shybovycha
    Jul 29, 2011 at 10:08
  • And yes, this issue is present for another account.
    – shybovycha
    Jul 29, 2011 at 10:10

3 Answers 3


The solution was pretty elegant and simple: editing /etc/inputrc and disabling vi mode.

Here's the renewed inputrc file:

# /etc/inputrc - global inputrc for libreadline
# See readline(3readline) and `info rluserman' for more information.

# Be 8 bit clean.
set input-meta on
set output-meta on

#set editing-mode vi

# To allow the use of 8bit-characters like the german umlauts, uncomment
# the line below. However this makes the meta key not work as a meta key,
# which is annoying to those which don't need to type in 8-bit characters.

# set convert-meta off

# try to enable the application keypad when it is called.  Some systems
# need this to enable the arrow keys.
# set enable-keypad on

# see /usr/share/doc/bash/inputrc.arrows for other codes of arrow keys

# do not bell on tab-completion
# set bell-style none
# set bell-style visible

# some defaults / modifications for the emacs mode
#$if mode=emacs

# allow the use of the Home/End keys
"\e[1~": beginning-of-line
"\e[4~": end-of-line

# allow the use of the Delete/Insert keys
"\e[3~": delete-char
"\e[2~": quoted-insert

# mappings for "page up" and "page down" to step to the beginning/end
# of the history
# "\e[5~": beginning-of-history
# "\e[6~": end-of-history

# alternate mappings for "page up" and "page down" to search the history
# "\e[5~": history-search-backward
# "\e[6~": history-search-forward

# 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

$if term=rxvt
"\e[8~": end-of-line
"\eOc": forward-word
"\eOd": backward-word

# for non RH/Debian xterm, can't hurt for RH/Debian xterm
# "\eOH": beginning-of-line
# "\eOF": end-of-line

# for freebsd console
# "\e[H": beginning-of-line
# "\e[F": end-of-line


Should read more 'bout that modes. Thanks everybody for the trouble-taking!


I've had the same problem. My /etc/inputrc was configured correctly, but due to some strange reason I had skeleton configuration in ~/.inputrc which then disabled all the mappings in /etc/inputrc.

So, my solution was:

rm ~/.inputrc
  • 1
    I had a strange, empty ~/.inputrc file. After I deleted it, as you said, I opened a new shell, and it was fixed. Thanks! Sep 10, 2016 at 23:50
  • @BrianPeterson same here! I wonder why .inputrc overwrites /etc/inputrc.Maybe it is meant to be an easy way to saying "I want to start from a clean plate"? anyway, you can still keep the .inputrc file and add $include /etc/inputrc as first line. This will allow you to keep the defaults and modify some if it.
    – ychaouche
    Apr 19, 2022 at 16:06

According to nano's title bar, you are editing a bash history file after you press v:


I suspect that Ctrl-Left and Ctrl-Right are activating the interactive history mode.

Does your .bashrc contain bindings for history-search-backward and history-search-forward?

You can disable this behaviour by commenting out, or removing, any of those bind lines in your .bashrc or in .bash_aliases.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .