摘要: Using markshttp://vim.wikia.com/wiki/Using_marks1. There is no visible indication of where marks are set.2. Each file has a set of marks identified by 阅读全文
posted @ 2016-12-02 16:52 cnblogist 阅读(137) 评论(0) 推荐(0) 编辑
摘要: copy complete current line: yy replace a char (e.g. comma) to new line: %s/,/\r/g 阅读全文
posted @ 2016-12-02 15:32 cnblogist 阅读(166) 评论(0) 推荐(0) 编辑
摘要: 1. buffer switching http://vim.wikia.com/wiki/Easier_buffer_switching :buffer:ls:files 2. vim default to delete a buffer, it causes closing the window 阅读全文
posted @ 2016-12-02 15:29 cnblogist 阅读(299) 评论(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 阅读全文
posted @ 2016-12-02 13:08 cnblogist 阅读(486) 评论(0) 推荐(0) 编辑
摘要: http://superuser.com/questions/414110/vim-save-a-file-as-a-different-filename-but-keep-w-as-the-current-filename :w someOtherFile.c it will write to t 阅读全文
posted @ 2016-12-02 12:47 cnblogist 阅读(208) 评论(0) 推荐(0) 编辑
摘要: http://vim.wikia.com/wiki/Uniq_-_Removing_duplicate_lines :sort u 阅读全文
posted @ 2016-12-02 12:41 cnblogist 阅读(124) 评论(0) 推荐(0) 编辑