User Tools

Site Tools


linux:vim

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
linux:vim [2013/10/12 16:07] – [NERDTree] percylinux:vim [2016/08/15 16:25] (current) – [Vim tips] percy
Line 5: Line 5:
 open/close folder open/close folder
   zf/zo   zf/zo
 +   
 +   :%!xxd 
 +   :%!xxd -r
 ===== Split ===== ===== Split =====
   :split filename   :split filename
Line 17: Line 19:
   Ctrl+w:H,J,K,L   Ctrl+w:H,J,K,L
   Ctrl+w:w   Ctrl+w:w
 +
 +==== select ====
 +  v
 +  ctrl+v select a block
  
 ===== Reference ===== ===== Reference =====
Line 65: Line 71:
 http://corner.squareup.com/2013/08/fly-vim-first-class.html http://corner.squareup.com/2013/08/fly-vim-first-class.html
   git clone https://github.com/square/maximum-awesome.git && cd maximum-awesome && rake   git clone https://github.com/square/maximum-awesome.git && cd maximum-awesome && rake
 +  
 + 
 +==== Maximum Awesome Linux ====
 +  https://github.com/pjq/maximum-awesome-linux
 + ==== paste ====
 +  :set paste
 +  :set nopaste
 +Install the macvim to replace the system vim
 +  brew install macvim --HEAD --override-system-vim
 +  
 +==== ctags ====
 +  sudo port install ctags
 +  ctags -R
 +
 +Append ~/.vimrc
 +  set tags=tags;
 +  set autochdir
 +  
 +==== taglist ====
 +Download the latest taglist from here:
 +http://www.vim.org/scripts/script.php?script_id=273
 +<code>
 +"taglist
 +map <silent> <F8> :TlistToggle<cr>  
 +""""""""""""""""""""""""""""""
 +" Tag list (ctags)
 +""""""""""""""""""""""""""""""
 +let Tlist_Ctags_Cmd = 'ctags'
 +let Tlist_Show_One_File = 1            "不同时显示多个文件的tag,只显示当前文件的
 +let Tlist_Exit_OnlyWindow = 1          "如果taglist窗口是最后一个窗口,则退出vim
 +let Tlist_Use_Right_Window = 1         "在右侧窗口中显示taglist窗口    
 +</code>
 +
 +
 +==== run command ====
 +  !ls
 +  r !ls
 +  
 +  
 +==== Vim tips ====
 +<code>
 +^M is retrieve by cmd+v, M
 +</code>
 +  
 +  1,%s/^M//g
 +
 +
 + 
 +  
 +
/var/www/dokuwiki/wiki/data/attic/linux/vim.1381565273.txt.gz · Last modified: 2016/05/05 13:06 (external edit)