首页 > 系统服务 > 详细

vim - copy a word

时间:2016-12-02 14:15:06      阅读:412      评论:0      收藏:0      [点我收藏+]

1. http://stackoverflow.com/questions/7797068/copying-a-word-and-pasting-over-a-word

viwp - visually select a word, and paste over it by something in the clip.

 

2. How to copy/delete word under cursor in Vim
http://www.littletechtips.com/2011/05/how-to-copydelete-word-under-cursor-in.html

Assuming the cursor is at the first character of the word in command mode:
yw (y for yank and w for word)

Other ways of doing the same thing which are not as efficient:
vey (v starts visual mode. e tells vim to move to end of word. y yanks or copies the word. to delete replace y with x.)

if the cursor is somewhere in the middle of the word, add a "b" (before) the command:
byw / bvey

vim - copy a word

原文:http://www.cnblogs.com/cnblogist/p/6125352.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!