In Vim/Vi, how do you move the cursor to the end o

2019-03-07 20:56发布

In Vim's normal mode:

  • e goes to the end of the next word
  • w goes to the beginning of the next word
  • b goes to the beginning of the previous word

How do you move the cursor to the end of the previous word?

标签: vim vi
3条回答
贼婆χ
2楼-- · 2019-03-07 21:14

Unfortunately it's not a single key... but ge is what you're looking for, I think.

查看更多
Anthone
3楼-- · 2019-03-07 21:20

as seen on VIM manual (section 03.1), you can use ge to go to the end of previous word

查看更多
淡お忘
4楼-- · 2019-03-07 21:25

Try ge:

ge                      Backward to the end of word [count] |inclusive|.

                                                        *gE*
gE                      Backward to the end of WORD [count] |inclusive|.
查看更多
登录 后发表回答