Skip to content
Browse files

vim: minor changes.

  • Loading branch information...
1 parent b8ed704 commit 0ffe85af63c5e6ae140743e959bb8183d2f9f232 @sjl committed Feb 25, 2011
Showing with 12 additions and 5 deletions.
  1. +11 −4 vim/.vimrc
  2. +1 −1 vim/castrate.py
View
15 vim/.vimrc
@@ -40,6 +40,7 @@ set list
set listchars=tab:\ ,eol:¬
set shell=/bin/bash
set lazyredraw
+set wildignore+=*.pyc,.hg
" Save when losing focus
au FocusLost * :wa
@@ -292,13 +293,16 @@ inoremap <C-_> <Space><BS><Esc>:call InsertCloseTag()<cr>a
" Faster Esc
inoremap jk <ESC>
-" TextMate-Style Autocomplete
-inoremap <ESC> <C-P>
-inoremap <S-ESC> <C-N>
-
" Scratch
nmap <leader><tab> :Sscratch<cr><C-W>x<C-j>:resize 15<cr>
+" Better Completion
+set completeopt=longest,menuone
+inoremap <expr> <CR> pumvisible() ? "\<C-y>" : "\<C-g>u\<CR>"
+inoremap <expr> <C-p> pumvisible() ? '<C-n>' : '<C-n><C-r>=pumvisible() ? "\<lt>up>" : ""<CR>'
+inoremap <expr> <C-n> pumvisible() ? '<C-n>' : '<C-n><C-r>=pumvisible() ? "\<lt>Down>" : ""<CR>'
+
+
" Make selecting inside an HTML tag less dumb
nnoremap Vit vitVkoj
nnoremap Vat vatV
@@ -366,6 +370,9 @@ let vimclojure#SplitPos = "right"
let g:syntastic_enable_signs=1
let g:syntastic_disabled_filetypes = ['html', 'python']
" }}}
+" Command-T {{{
+let g:CommandTMaxHeight = 20
+" }}}
" }}}
" Synstack -------------------------------------------------------------------- {{{
View
2 vim/castrate.py 100644 → 100755
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/env python
# Original source: http://forrst.com/posts/An_unball_script_for_vimball_plugins-CHM
import os, sys

0 comments on commit 0ffe85a

Please sign in to comment.
Something went wrong with that request. Please try again.