Created
September 3, 2012 10:03
-
-
Save zudochkin/3608239 to your computer and use it in GitHub Desktop.
.vimrc
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
call pathogen#infect() | |
set nocompatible | |
syntax on | |
set nu | |
set ruler | |
" настраиваем табуляцию | |
set shiftwidth=2 | |
set tabstop=2 | |
set expandtab | |
set cindent | |
set smartindent | |
set autoindent | |
" подсветить результаты поиска | |
set hlsearch | |
set incsearch " do incremental searching | |
" Switch wrap off for everything | |
set nowrap | |
set showcmd " display incomplete commands | |
" Always display the status line | |
set laststatus=2 | |
" , is the leader character | |
let mapleader = "," | |
" Hide search highlighting | |
map <Leader>h :set invhls <CR> | |
" где хранить swp файлы | |
set dir=~/.vim/swp | |
" нужно для работы макросов | |
filetype plugin indent on | |
" работа с "табами" | |
map <silent> <C-T> :tabnew<CR> | |
map <silent> <C-Left> :tabprev<CR> | |
map <silent> <C-Right> :tabnext<CR> | |
"map <silent> <C-Q>, Q :tabclose<CR> | |
" ruby | |
au! BufRead,BufNewFile Gemfile set filetype=ruby | |
" Keep more content at the bottom of the buffer | |
set scrolloff=5 | |
" Highlight cursor line | |
set cursorline | |
set history=1000 | |
" Thorfile, Rakefile, Vagrantfile and Gemfile are Ruby | |
au BufRead,BufNewFile {Gemfile,Rakefile,Vagrantfile,Thorfile,config.ru} set ft=ruby | |
" | |
" " md, markdown, and mk are markdown and define buffer-local preview | |
au BufRead,BufNewFile *.{md,markdown,mdown,mkd,mkdn} set ft=markdown | |
" | |
" " add json syntax highlighting | |
au BufNewFile,BufRead *.json set ft=javascript | |
colorscheme peachpuff | |
runtime macros/matchit.vim | |
" вставляем linebreak в normal mode | |
:nnoremap <NL> i<CR><ESC> | |
set wildmenu | |
set wcm=<Tab> | |
menu Exec.RSpec-line :exe "!rspec " . expand('%') . ":" . line(".") <CR> | |
menu Exec.RSpec-file :!rspec % <CR> | |
menu Exec.Ruby :!ruby % <CR> | |
map <F9> :emenu Exec.<Tab> | |
if has("gui_running") | |
set guifont=Ubuntu\ Mono\ 14 | |
"colorscheme solarized | |
colorscheme codeschool | |
endif | |
let g:ackprg="ack-grep -H --nocolor --nogroup --column" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment