" =============================================================================
let Tlist_Exit_OnlyWindow=1                 "如果Taglist窗口是最后一个窗口则退出Vim
"        << 判断操作系统是 Windows 还是 Linux 和判断是终端还是 Gvim >>
" =============================================================================

" -----------------------------------------------------------------------------
"  < 判断操作系统是否是 Windows 还是 Linux >
" -----------------------------------------------------------------------------
let g:iswindows = 0
let g:islinux = 0
if(has("win32") || has("win64") || has("win95") || has("win16"))
    let g:iswindows = 1
else
    let g:islinux = 1
endif

" -----------------------------------------------------------------------------
"  < 判断是终端还是 Gvim >
" -----------------------------------------------------------------------------
if has("gui_running")
    let g:isGUI = 1
else
    let g:isGUI = 0
endif

 

 

" -----------------------------------------------------------------------------
"  < 个人偏好快捷键设置 >
" -----------------------------------------------------------------------------

"修改映射键为jk退出INSERT模式
inoremap jk

"以新的页签打开当前光标处的文件,而非原本的覆盖打开
nmap gf :tab vsp

"将一行文本从光标处进行换行
"nmap K a

"快捷新建shell解释器头
nmap bi ggdG0i#!/bin/bash

"全局代码对齐,四个空格为缩进单位
nmap fm mzgg='z

"快捷新建c语言常用头文件
nmap ci ggdG0i#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include int main(void){return 0;}22gg
" -----------------------------------------------------------------------------