Monday, October 30, 2006

getting ctrl-forward/backward working on cygwin and sles

I am used to jumping forward and backward a word on the console while typing a command. As the command gets bigger, moving around the command to change things get tougher if you cannot move one word at a time.

I am working on windows cygwin, and i use the cygwin sshd service to give me ssh access to the windows machine, so that i can work from a familiar linux environment! Now cygwin did not allow me to use the ctrl-left arrow and ctrl-right arrow to move around the command.

Here is the solution: Add the following to you ~/.inputrc file

"\e[5C": forward-word
"\e[5D": backward-word
"\e[1;5C": forward-word
"\e[1;5D": backward-word

And you should be able to jump words!


  1. Thanks, you rock! This is exactly what I needed to know!

  2. thank you for this! didn't know how to configure it.