首页
学习
活动
专区
工具
TVP
发布
精选内容/技术社群/优惠产品,尽在小程序
立即前往

vim 基础配置

最近在使用 python 搞服务, 简单配置了一个 vim, 配置了自动补全以及背景色 。(ps:搜狗输入法快捷键占用真是太坑爹,改用谷歌输入法,世界安静了)

具体配置如下:

代码语言:javascript
复制
 1 set nocompatible              " be iMproved, required
  2 filetype off                  " required
  3 
  4 " set the runtime path to include Vundle and initialize
  5 set rtp+=~/.vim/bundle/Vundle.vim
  6 call vundle#begin()
  7 " alternatively, pass a path where Vundle should install plugins
  8 
  9 " let Vundle manage Vundle, required
 10 Plugin 'VundleVim/Vundle.vim'
 11 
 12 " python auto-complete
 13 Plugin 'davidhalter/jedi-vim'
 14 
 15 " tab 
 16 Plugin 'ervandew/supertab'
 17 
 18 " background
 19 Plugin 'altercation/vim-colors-solarized'
 20 
 21 
 22 " All of your Plugins must be added before the following line
 23 call vundle#end()            " required
 24 filetype plugin indent on    " required
 25 
 26 
 27 let g:SuperTabDefaultCompletionType = "context"
 28 let g:jedi#popup_on_dot = 0
 29 
 30 syntax on
 31 set background=dark
 32 colorscheme solarized
 33 let g:solarized_termcolors=256
 34 
 35 set number

函数跳转功能:

1、安装 c-tags:  

代码语言:javascript
复制
sudo apt-get install exuberant-ctags

 2、创建 tags, 在项目文件目录下

代码语言:javascript
复制
ctags -R .

3、使用

跳转: Ctrl + ] 

返回: Ctrl + T

举报
领券