Skip to content

Commit

Permalink
Replaced previous autocompletion libraries with YouCompleteMe
Browse files Browse the repository at this point in the history
  • Loading branch information
dbrgn committed Mar 26, 2013
1 parent 46b354e commit df37f4d
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 20 deletions.
30 changes: 10 additions & 20 deletions .vimrc
Expand Up @@ -22,9 +22,6 @@ Bundle 'gmarik/vundle'
" Command-T
Bundle 'Command-T'

" Supertab
Bundle 'ervandew/supertab'

" Snipmate
Bundle 'MarcWeber/vim-addon-mw-utils'
Bundle 'tomtom/tlib_vim'
Expand All @@ -39,8 +36,7 @@ Bundle 'fs111/pydoc.vim'
Bundle 'groenewege/vim-less'

" Autocompletion
Bundle 'davidhalter/jedi-vim'
Bundle 'rubycomplete.vim'
Bundle 'Valloric/YouCompleteMe'

" Zen coding
Bundle 'mattn/zencoding-vim'
Expand Down Expand Up @@ -142,21 +138,12 @@ command! WQ wq
let g:pyflakes_use_quickfix = 0

" Configure flake8
let g:flake8_ignore="E126,E127,E128"
let g:flake8_max_line_length="99"

" Configure tab completion
au FileType python set omnifunc=jedi#complete
au FileType ruby,eruby set omnifunc=rubycomplete#Complete
au FileType ruby,eruby let g:rubycomplete_buffer_loading = 1
au FileType ruby,eruby let g:rubycomplete_rails = 1
au FileType ruby,eruby let g:rubycomplete_classes_in_global = 1
let g:SuperTabDefaultCompletionType = "context"
set completeopt=menuone,longest,preview
let g:flake8_ignore = "E126,E127,E128"
let g:flake8_max_line_length = "99"

" Starting with Vim 7, the filetype of empty .tex files defaults to 'plaintex'
" instead of 'tex'. The following changes the default filetype back to 'tex'
let g:tex_flavor='latex'
let g:tex_flavor = 'latex'

" Compile latex and restart mupdf
map <leader>l :w<CR> :!rubber -m pdftex % && killall -HUP mupdf<CR><CR>
Expand All @@ -165,13 +152,16 @@ map <leader>l :w<CR> :!rubber -m pdftex % && killall -HUP mupdf<CR><CR>
map <leader>m :w<CR> :!make<CR><CR>
" Configure Command-T behavior
let g:CommandTAcceptSelectionTabMap='<CR>'
let g:CommandTAcceptSelectionSplitMap='<C-CR>'
let g:CommandTAcceptSelectionTabMap = '<CR>'
let g:CommandTAcceptSelectionSplitMap = '<C-CR>'

" Configure snipmate
let g:snips_author='Danilo Bargen'
let g:snips_author = 'Danilo Bargen'
let g:snipMateAllowMatchingDot = 0

" Configure YCM
let g:ycm_autoclose_preview_window_after_completion=1

" Configure GTK syntax highlighting
let glib_deprecated_errors = 1

Expand Down
7 changes: 7 additions & 0 deletions README.md
Expand Up @@ -13,6 +13,8 @@ Contains many tools for Python development.

* vim compiled with Python and Ruby support
* C compiler and Ruby (to build command-t extensions)
* C++ compiler and Python headers
* Jedi (https://github.com/davidhalter/jedi)

### Setup

Expand All @@ -36,6 +38,11 @@ Configure command-t
ruby extconf.rb
make

Configure YCM

cd ~/.vim/bundle/YouCompleteMe/
./install.sh --clang-comp


## Bash

Expand Down

0 comments on commit df37f4d

Please sign in to comment.