vim.rc配置(deepin)
set nocompatible " be iMproved, required
filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" alternatively, pass a path where Vundle should install plugins
"call vundle#begin('~/some/path/here')
" let Vundle manage Vundle, required
Plugin 'VundleVim/Vundle.vim'
" The following are examples of different formats supported.
" Keep Plugin commands between vundle#begin/end.
" plugin on GitHub repo
Plugin 'tpope/vim-fugitive'
" plugin from http://vim-scripts.org/vim/scripts.html
" Plugin 'L9'
" Git plugin not hosted on GitHub
"Plugin 'git://git.wincent.com/command-t.git'
" git repos on your local machine (i.e. when working on your own plugin)
"Plugin 'file:///home/gmarik/path/to/plugin'
" The sparkup vim script is in a subdirectory of this repo called vim.
" Pass the path to set the runtimepath properly.
Plugin 'rstacruz/sparkup', {'rtp': 'vim/'}
" Install L9 and avoid a Naming conflict if you've already installed a
" different version somewhere else.
" Plugin 'ascenator/L9', {'name': 'newL9'}
Plugin 'mhinz/vim-startify'
Plugin 'aperezdc/vim-template'
Plugin 'thinca/vim-quickrun'
Plugin 'jiangmiao/auto-pairs'
Plugin 'Chiel92/vim-autoformat'
"" Theme Plugin
Plugin 'sjl/badwolf'
" All of your Plugins must be added before the following line
call vundle#end() " required
filetype plugin indent on " required
" To ignore plugin indent changes, instead use:
"filetype plugin on
"
" Brief help
" :PluginList - lists configured plugins
" :PluginInstall - installs plugins; append `!` to update or just :PluginUpdate
" :PluginSearch foo - searches for foo; append `!` to refresh local cache
" :PluginClean - confirms removal of unused plugins; append `!` to auto-approve removal
"
" see :h vundle for more details or wiki for FAQ
" Put your non-Plugin stuff after this line
"" display settings
set t_Co=256
syntax enable
syntax on
set background=dark
colorscheme badwolf
set cursorline
set cursorcolumn
set number
" file encoding
set fileencodings=ucs-bom,utf-8,cp936,gb18030,big5,euc-jp,euc-kr,latin1
" enable mouse
set mouse=a
" indent
set expandtab
set tabstop=4
set softtabstop=4
set shiftwidth=4
" fold
set nofoldenable
set foldmethod=syntax
" search
set hlsearch
set incsearch
" case
set ignorecase
set smartcase
" keep 200 lines of command line history
set history=200
" Show a few lines of context around the cursor.
" Note that this makes the text scroll
" if you mouse-click near the start or end of the window.
set scrolloff=5
set sidescrolloff=5
" display completion matches in a status line
set wildmenu
" display incomplete commands
set showcmd
" Allow backspacing over everything in insert mode.
set backspace=eol,start,indent
" Use ; as <Leader>
let mapleader = ";"
" Quick select whole file
nnoremap <Leader>a ggVG
" Quick save or quit file
nnoremap <Leader>w :w<CR>
nnoremap <Leader>q :q<CR>
nnoremap <Leader>fq :q!<CR>
" Copy to and paste from system clipboard
nnoremap <Leader>y "+y
nnoremap <Leader>p "+p
nnoremap <Leader>fz ggVG"+y
" vim smart autocomplete
set wildmenu
" man the information
nnoremap <Leader>man :Man <cword><CR>
"""" Plugin settings
" vim-startify
let g:startify_files_number = 20
" vim-template
let g:templates_no_autocmd=1
let g:templates_directory='~/.vim/templates'
nnoremap <Leader>tp2 :Template tp2<CR>
" vim-quickrun
let g:quickrun_config = {
\ "_" : {
\ "outputter" : "message",
\ },
\}
let g:quickrun_no_default_key_mappings = 1
nmap <F5> <Plug>(quickrun)
" YouCompleteMe
let g:ycm_collect_identifiers_from_tags_files=1
set tags+=~/.tags/stdcpp.tags
let g:ycm_global_ycm_extra_conf='~/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/ycm/.ycm_extra_conf.py'
let g:ycm_complete_in_comments=1
let g:ycm_cache_omnifunc=0
let g:ycm_seed_identifiers_with_syntax=1
set completeopt-=preview
" Airline
let g:airline_theme='luna'
let g:airline_powerline_fonts = 1
if !exists('g:airline_symbols')
let g:airline_symbols = {}
endif
let g:airline_symbols.linenr = '&'
" AutoFormat
let g:formatdef_my_cpp = '"astyle --style=google"'
let g:formatters_cpp = ['my_cpp']
"au BufWrite * :Autoformat
nmap <Leader>fmt <Plug>(Autoformat)
""" My Own Function
func! CppDebug()
exe "silent !g++ -O0 -std=c++14 -g % -o %<"
exe "!gdb %<"
exe "silent !rm -rf %<"
endfunc
nnoremap <Leader>db :call CppDebug()<CR>
map <F6> :call Run()<CR>
func! Run()
exe "silent w"
exe "silent !g++ % -o %<"
exe "!./%<"
exe "silent !rm %<"
endf
vim.rc配置(deepin)的更多相关文章
- [转] vim自定义配置 和 在ubnetu中安装vim
Ubuntu 12.04安装vim和配置 问题: ubuntu默认没有安装vim,出现: jyg@ubuntu:~$ vim test.cThe program 'vim' can be foun ...
- 为了让vi命令也可以使用vim的配置,需要修改 vi /etc/bashrc 增加一行 alias vi='vim'此时,经过上面配置已经可以显示语法高亮了
为了让vi命令也可以使用vim的配置,需要修改 vi /etc/bashrc 增加一行 aliasvi='vim'此时,经过上面配置已经可以显示语法高亮了
- 我的VIM.rc
我的VIM.rc """""""""""""""& ...
- linux环境下Vim的配置
原文链接:http://blog.chinaunix.net/uid-26826958-id-3272375.html (本文转自此链接中的部分内容,但做了适当修改) 安装vim命令:sudo ap ...
- windows下LINUX模拟终端Cypwin以及Vim的配置使用
Cypwin的安装 从官网下载相应版本后,直接安装. 官网地址:Cypwin 安装过程中可以选择相应的Packages,我们需要安装的Vim就需要在这一步中选择相应的包. Cypwin的使用 纯命令行 ...
- VIM简单配置
配置vim配置 编辑配置文件 feng@mint ~ $ vim ~/.vimrc 配置如下 主要配置为自动换行,设置行号,设置tab键为4个空格,同时将tab键自动转换成空格 set autoind ...
- macOS中Vim基本配置,颜色主题/语法/indent设置
macOS中Vim基本配置 Vim的初始化配置 .vimrc 存放位置 macOS 环境下 vim 的初始化配置文件为 .vimrc , 通常有两个(系统版本和用户版本),一个位于 /usr/shar ...
- vim基本配置备份
我的vim基本配置如下,在这里作个备份: set background=light syntax on set number set smartindent set expandtab set tab ...
- Linux - vim安装 配置与使用
一 Vim 简单介绍 曾经一直用vi,近期開始使用 vim,以下将两者做一下比較. vi和vim都是word=%E5%A4%9A%E6%A8%A1&fr=qb_search_exp&i ...
随机推荐
- (五)mybatis开发dao层
目录 SqlSession 是线程不安全的 原始 dao 开发方法 Mapper 代理方法 关于代理对象 SqlSession 是线程不安全的 SqlSession 是 线程不安全 的: 对于它,我们 ...
- 6.Linux查看哪个进程占用磁盘IO
$ iotop -oP命令的含义:只显示有I/O行为的进程
- 什么是Sprint?
Sprint指Scrum团队完成一定数量工作所需的短暂.固定的周期.Sprint是Scrum和敏捷的核心,找到正确的Sprint周期将帮助您的敏捷团队交付更高质量的产品. “在Scrum框架中,庞大且 ...
- Guide 哥:有哪些程序员受用一生的好习惯?
本文来自 Guide 哥开源的 Github 仓库 programmer-advancement:https://github.com/Snailclimb/programmer-advancemen ...
- 异常:Invalid character found in the request target. The valid characters are defined in RFC 3986
一.背景 事情是这样的,前几天做一个基本的数据库“增删改查”的需求,前端传参的方式是“JSON字符串”,后端接收到此参数后,使用阿里巴巴fastjson进行解析,然后入库.需求很简单吧,但是偏偏遇到问 ...
- 处理python错误问题
------------恢复内容开始------------ 调试过程中遇到的问题 (1)爬取首页源码出现中文乱码 解决方案: 将网页编码强制转换成gbk,并去除解决乱码问题的三行代码. (2)程序运 ...
- spring利用xml配置定时任务
在开发中会经常遇到做定时任务的需求,例如日志定时清理与处理,数据信息定时同步等需求. 1.在spring中利用xml配置定时任务,如下 <!-- ftpiptv信息同步接口定时任务配置--> ...
- 日志实时收集之FileBeat+Kafka
之前,我们的某一个业务用于实时日志收集处理的架构大概是这样的: 在日志的产生端(LogServer服务器),都部署了FlumeAgent,实时监控产生的日志,然后发送至Kafka.经过观察,每一个 ...
- ES6入门六:class的基本语法、继承、私有与静态属性、修饰器
基本语法 继承 私有属性与方法.静态属性与方法 修饰器(Decorator) 一.基本语法 class Grammar{ constructor(name,age){ //定义对象自身的方法和属性 t ...
- 文件的空间使用和IO统计
数据库占用的存储空间,从高层次来看,可以查看数据库文件(数据文件,日志文件)占用的存储空间,从较细的粒度上来看,分为数据表,索引,分区占用的存储空间.监控数据库对象占用的硬盘空间,包括已分配,未分配, ...