From 783333144d6c03c6c5d52a88e0790617de0767ee Mon Sep 17 00:00:00 2001 From: "Andrew R. M" Date: Fri, 16 Dec 2016 10:22:32 -0500 Subject: [PATCH] Improved vim tab completion --- vimrc | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/vimrc b/vimrc index 8721c34..68cfb40 100644 --- a/vimrc +++ b/vimrc @@ -9,6 +9,22 @@ set nocompatible runtime bundle/pathogen/autoload/pathogen.vim execute pathogen#infect() + "{- SUPERTAB -}" + set complete+=kspell + set completeopt=longest,menuone + + " Use context sensitive completion to allow filename and omni completion + let g:SuperTabDefaultCompletionType = "context" + + " Completion context only lasts for current completion + let g:SuperTabRetainCompletionDuration = "completion" + + " Use enhanced longest matching completion + let g:SuperTabLongestEnhanced = 1 + + " Attempt to close preview window when the completion finishes + let g:SuperTabClosePreviewOnPopupClose = 1 + "{- COMMANDS -}" " Remove blank lines " @@ -42,6 +58,7 @@ set nocompatible set softtabstop=4 set shiftwidth=4 set tabstop=4 + set expandtab " Don't redraw the screen unless necessary " set lazyredraw