zoukankan      html  css  js  c++  java
  • mini vimrc

     Mini version:

    set enc=utf-8 ffs=unix,dos,mac lm=zh_CN.utf-8
    set nu nowb nocp nowrap ru nobk sm is noswf acd hls autoread 
    set hi=700 mouse=a sel=exclusive slm=mouse,key
    set cin sta et ai si ts=4 bs=2 sw=4 sts=4
    set guifont=DejaVu Sans Mono 14
    colorscheme desert
    syntax on
    filetype indent plugin on
    map <C-s> <ESC>:wall<CR>

    Full version:

    "----Encoding setting----
    set enc=utf-8                   "encoding
    set ffs=unix,dos,mac            "fileformats
    set lm=zh_CN.utf-8              "langmenu
    
    "----Basic function----
    set nu                          "number
    set nowb                        "nowritebackup  禁止自动保存
    set nocp                        "nocompatible   去除vi一致性
    set ru                          "ruler          显示标尺
    set nobk                        "nobackup       禁止缓冲保存
    set sm                          "showmatch      符号自动匹配
    set is                          "incsearch      搜索增强模式
    set noswf                       "noswapfile     去除swap文件
    set hi=700                      "history        最大历史记录
    set acd                         "autochdir      设置为当前文件目录
    set hls                         "highlightsearch 高亮搜索
    set ar                          "autoread       自动读文件
    "----Mouse setting----
    set mouse=a                     "mouse          鼠标模式
    set sel=exclusive               "selection      不包含最后的换行符
    set slm=mouse,key               "selectmode     选择模式
    
    "----Indent habit----
    set nowrap                      "nowrap         不自动换行
    set cin                         "cindent        C格式缩进
    set sta                         "smarttab       智能tab
    set et                          "expandtab      tab=backspace
    set ts=4                        "tabstop        tab=4个字符
    set ai                          "autoindent     自动缩进
    set si                          "smartindent    智能缩进
    set bs=2                        "backspace      =indent,eol,start
    set sw=4                        "shiftwidth     自动缩进设置为4个字符
    set sts=4                       "softtabstop    按一次tab 前进4个字符
    
    "一键ctrl+s保存
    map <C-s> <ESC>:wall<CR>
    
    "----Theme setting----
    syntax on                       "开启高亮
    colorscheme desert              "主题配色
    set guifont=DejaVu Sans Mono 14
    
    "----Autoread the text----  
    filetype on                     "自动识别文件类型
    

      

  • 相关阅读:
    Luogu P2480 [SDOI2010]古代猪文 卢卡斯+组合+CRT
    luogu 3806 【模板】点分治
    poj 1741 Tree(树的点分治)
    置换群(本蒟蒻瞎BB的)(未完)
    uva 1153 顾客是上帝(贪心)
    关于区间的贪心问题
    uva 1615 高速公路(贪心,区间问题)
    uva 1614奇怪的股市(归纳法证明,贪心)
    uva11491 奖品的价值(贪心)
    uva12545 比特变换器(贪心)
  • 原文地址:https://www.cnblogs.com/Felix-F/p/3867549.html
Copyright © 2011-2022 走看看