dw: delete current word, but first thing for this command is the cursor has to be the first character of the word.
d$: delete to the end of the line
0: move to the end of the line.
d3w: delete the 3 words after the cursor. d4w will delete 4 words
U: To undo all the changes on a line
p: put the line which deleted by command 'dd' under the cursor line
r: Type rx to replace the character at the cursor with x
ce: To change until the end of a word, type ce
c$: Delete the context from cursor to the end of the line, and go the input mode
ctrl+g : To show your location in the file and the file status.
G: Go to the bottom of the file.
gg: To move you to the start of the file.
G: Type the number of the line you want to go and then G, this will go to the line you wann to go.
/: search for the phrase from forward
?: search for the phrase from backward
n: search the same phrase again, simple type n
N: search the same phrase in the opposite direction, type N
ctrl+o: To go back to where you came from. Repeat to go back further
ctrl+i: To go forward
%: to find a matching ),], or }. This is very useful in debugging a program with unmatched parentheses
:s/old/new/ to substitute 'new' for 'old', only change the first occurrence
:s/old/new/g to substitute 'new' for 'old', will change all the occurrences in the line
:%s/old/new/g to change every occurrence in the whole file
:%s/old/new/gc to find every occurrence in the whole file, with a prompt whether to substitute or not
o: to open a line below the cursor and place you in insert mode.
O: to open a line above the cursor and place you in insert mode.
a: to insert text AFTER the cursor
i: to insert text BEFORE the cursor
A: to insert text at the end of line
R: replace more than one character
r: replace one character of cursor position
copy and paste:
1. start visual mode with v and move the cursor to select the text you want to copy
2. Type y to yank(copy) the highlighted text.
3. Go to the position which you want to paste your text
4. Type p to put(paste) the tex
分享到:
相关推荐
vim-notes, 在Vim中,轻松记下 轻松笔记在Vim中Vim Vim插件的Vim注释使得你可以轻松地在Vim中管理便笺:开始新便笺的开始时间: 运行命令以创建新的缓冲区并加载适当的文件类型和语法你还可以使用诸如 :edit,:...
Mastering Vim: Build a ... He started publishing personal Vim notes in 2012, and became increasingly interested in the intricacies of the editor and its applications in optimizing development workflows.
Vim learning notes. My personal notes.
Vim方式提示1.: . , x , u , dd , >G , i , <Esc> 提示2.: $ , a , A 提示3: f{char} , s , ; 提示4.动作: F{char}/T{char} , /pattern<CR> :s/target/replacement 提示5.: /target , * , *nn , ...
vim-DevNotes devnotes.vim是一个vim( )插件,可以简化开发笔记的制作。 它还附带了一个有用的状态栏功能,可以快速查看仍有多少待处理的便笺。 截屏 安装 将所有文件复制到〜/ .vim目录,或使用Tim Pope出色的...
第九章 、vim 程序编辑器9.1.1 为何要学 vim9.2 vi 的使用9.2.1 简易执行范例9.2.2 按键说明9.2.3 一个案例练习9.2.4 vi
vimwiki同步这个插件: 在Vimwiki启动时自动同步Vimwiki notes目录,并使用Git退出。 它还会自动同步Task Warrior 更改的文件将自动提交。
notes:这些是我使用Vimwiki的笔记
mynotes.vim:Neovim Lua插件,用于管理我的个人笔记系统
[WIP] line-notes.nvim 在您只对您可见的文件中留下个人评论和注释。 仅限Neovim 0.5+。 仍处于非常Alpha阶段。 预期会有重大变化。 安装 " vim-packager call packager#add ( ' kristijanhusak/line-notes.nvim '...
我在Vim中完成大部分工作,所以为什么还要打开另一个窗口,其劣等的编辑功能却浪费了宝贵的屏幕空间。 抱歉,布雷特,但nvALT不能满足Vim的编辑速度。 我也不同意Notational Velocity哲学的某些部分。
:musical_notes: 介绍 vim-snoopy ( snoopy.vim ) 提供了一种监听脚本本地事物的方法。 您可以从 {path} 获取<SID> ,访问脚本本地函数,甚至脚本变量。 它还提供了一个命令来打开文件 (:SnoopyOpen)、类似函数的:...
万世通是一种古老,睿智和有力的精神,他为自己的精神图书馆收集信息。 该存储库是该库的我的版本。内容它包含有关编程,并发,数据库和算法的注释技术领域所有文件都使用语法。 文件夹结构是使用生成的
优点如下: 您可以使用收藏夹编辑器,例如Vim,Emacs,Sublime或Atom。 您的笔记更永久。 您上次删除git repo的时间是什么时候? 我也不记得我的。 储存Github是您保留几年历史的方式。 您的笔记由Git版本化。 ...
我的Vim配置。 提示 在Vim中查看本vimrc文件,高亮+折叠+ K文档: curl https://raw.githubusercontent.com/lilydjwg/dotvim/master/vimrc | vim -R -c ' setf vim ' - 注意 refs/notes/*有注释。
Pycharm使用记录新建文件模板的使用新建测试文件新建Python脚步文件时点击下面的下拉框即可与vim快捷键冲突设置在File->Setting->Vim
book-notes, 从书和其他有趣的东西中我读到 从书和其他有趣的东西中我读到。 enjoy!我如何做笔记的快速说明:在我的varchar上,我使用本书打开了Kindle应用程序,以及在文本编辑器( 通常是 sublime text 或者MacVim...
本人整理的GDScript教程(英文版),PDF版本,带目录,不喜欢的同学可以移步至http://www.reddit.com/r/godot/comments/1vcnen/notes_on_undocumented_tidbits/查看英文原版!
这些说明是我记录关于vi / vim / nvim的信息的地方。 我试图按以下顺序放置下面链接的MarkDown文件,即每个文件仅依赖于其之前的信息的要旨。 当Neovim升级到0.5版本,而Vim升级到9.0版本时,我感到它们之间的分歧...