This question already has an answer here:

When I use Ctrl+Left_arrow or Ctrl+Right_arrow in bash, I move backward a "word" and forward a "word" respectively. I belive, this is defined in /etc/inputrc

# 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

Unfortunately, the definition of "word" here is misleading. It considers /foo/bar as two words.

Is it possible to modify this so that the only word delimiter is space character ? (one or more spaces, or one or more tabs)

i.e. /foo/bar/ should be treated as one word

I am using Debian Wheezy

marked as duplicate by Gilles bash Apr 27 '15 at 23:56

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • Space is also a delimiter. – taliezin Apr 27 '15 at 20:47
  • @taliezin - I meant only space character and nothing else. I have modified my question to make it clear. – Martin Vegter Apr 27 '15 at 20:53
  • Sorry I did not get it. – taliezin Apr 27 '15 at 20:54

The thing is not delimiter but in words symbols which can be alphabet symbols, digit or underline only so any which is not from list count as delimiter.

Not the answer you're looking for? Browse other questions tagged or ask your own question.