在当前行上移动光标:0^$fFtT,;0→ 到行头 ^→ 到本行的第一个非blank字符 $→ 到行尾 g_→ ...
1) endif endfunction nnoremap K :call JumpPage(25)<CR> nnoremap J :call JumpPage(75)...
sort -> 从文件的开始第一个行一直执行到文件结束 (sort from start of file to end) :.10,15!sort -> 只在文件的第10行到第15行之间执行 (sort between line 10 to 15)
" All system-wide defaults are set in $VIMRUNTIME/debian.vim and sourced by " the call to :runtime you can find below. If you wish to change any of those " settings, you should do it in this file (/etc/vim/vimrc), since debian.vim " will be overwritten everytime an upgrade of...
例如guG 会把光标当前到文件结尾全部变成小写 (change lower case all the way to the end) gU -> 变成大写 (change to upper case) 例如gUG 会把光标当前到文件结尾全部变成大写 (change upper case all the way to the end) 复制与粘贴 (copy & paste) ...
C: resize to end of commit column D: resize to end of date/time column gq: close blame, then :Gedit to return to work tree version <CR>: close blame, and jump to patch that added line (or directly to blob for boundary commit) o: jump to patch or blob in horizontal split O: ju...
1. 替换当前行中的内容: :s/from/to/ (s即substitude) :s/from/to/ : 将当前行中的第一个from,替换成to。如果当前行含有多个 from,则只会替换其中的第一个。 :s/from/to/g : 将当前行中的所有from都替换成to。 :s/from/to/gc : 将当前行中的所有from都替换成to,但是每一次替换之前都会询问请求...
Skip to content Navigation MenuProduct Solutions Resources Open Source Enterprise Pricing Search or jump to... Sign in Sign up vim / vim Public Sponsor Notifications Fork 5.5k Star 37.1k Code Issues 1.5k Pull requests 49 Discussions Actions Projects Wiki Security 16 Insights ...
q# 录制macroa# assign an aliasShift+V# at line 293, enable visual-linej# select line 294y# yank selectedj# jump to line 294p# paste bufferq# end record To invoke a vim macro, @a 指定20次, 20@a VIM会将其重复20次。 2. 递增数字 ...
:g/keyword //筛选出包含keyword的行 :v/keyword //筛选出不包含keyword的行 :g/keyword/d //...