Yuan Yijun (bbbush) wrote,
Yuan Yijun

我爱 rst

更爱 vim
1 set nu ci is
2 augroup rst
3 "     autocmd Syntax rst execute "map <F5> <Esc><Esc>:w<CR>:!rst2html " . expand("<afile>") . " > 
" . expand("<afile>:r") . ".html<CR>"
4     autocmd Syntax rst map <F5> <Esc><Esc>:w<CR>:!rst2html % > %:r.html<CR>
5 augroup END

:source /usr/share/vim/vim70/syntax/2html.vim


一份比较全的 vimrc 在这里

windows 下面,我用这份 _vimrc, 忘了出处了。

colorscheme darkblue
set lines=40
set columns=150
set nu ci

" http://www.lidaibin.com/blog/index.php?action=show&id=44
" multi-encoding setting
if has("multi_byte")
  "set bomb
  set fileencodings=ucs-bom,utf-8,cp936,big5,euc-jp,euc-kr,latin1
  " CJK environment detection and corresponding setting
  if v:lang =~ "^zh_CN"
    " Use cp936 to support GBK, euc-cn == gb2312
    set encoding=cp936
    set termencoding=cp936
    set fileencoding=cp936
  elseif v:lang =~ "^zh_TW"
    " cp950, big5 or euc-tw
    " Are they equal to each other?
    set encoding=big5
    set termencoding=big5
    set fileencoding=big5
  elseif v:lang =~ "^ko"
    " Copied from someone's dotfile, untested
    set encoding=euc-kr
    set termencoding=euc-kr
    set fileencoding=euc-kr
  elseif v:lang =~ "^ja_JP"
    " Copied from someone's dotfile, untested
    set encoding=euc-jp
    set termencoding=euc-jp
    set fileencoding=euc-jp
  " Detect UTF-8 locale, and replace CJK setting if needed
  if v:lang =~ "utf8$" || v:lang =~ "UTF-8$"
    set encoding=utf-8
    set termencoding=utf-8
    set fileencoding=utf-8
  echoerr "Sorry, this version of (g)vim was not compiled with multi_byte"

Tags: 小东西

  • My tweets

    Wed, 09:34: WIthout threading support, Outlook managed to introduce "Focused" and "Other" as tabs in the inbox. Now I got two inbox to check.

  • My tweets

    Tue, 11:06: With IntelliJ IDEA it is really hard to tell which window is "active" by looking at the taskbar icon. The project n……

  • My tweets

    Sun, 21:01: Scared a little bit https://t.co/MQI4IPzfDa Sun, 22:07: https://t.co/22J8hD4xrp ugly paradise

  • Post a new comment


    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded