Last active
August 29, 2015 14:25
-
-
Save mactkg/ff797be51f037fa8433b to your computer and use it in GitHub Desktop.
Basic / Simple vimrc config file
This file contains 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
set nocompatible | |
set encoding=utf-8 | |
set hidden | |
filetype plugin indent on | |
syntax on | |
set synmaxcol=2048 " Don't syntax highlight super-long lines (for performance) | |
set autoindent " automatically indent lines and try to do it intelligently | |
set smartindent | |
set backspace=indent,eol,start " backspace behaves 'normally' | |
" set softtabstop=2 | |
set smartindent | |
set shiftwidth=4 " [2] | |
set tabstop=4 " tab is 4 spaces [2] | |
set expandtab " use soft tabs | |
set textwidth=0 | |
set nolinebreak | |
set nowrap | |
set virtualedit=all " Allow the cursor to go in to 'invalid' places | |
set hlsearch " highlight search terms | |
set incsearch " search incrementally | |
set ignorecase " ignore case in searches... | |
set smartcase " ...but not really. Case sensitive if capitals are included. | |
set wrapscan " Set the search scan to wrap around the file | |
nmap <silent> <Leader>/ :nohlsearch<CR> " Clear the find buffer | |
colorscheme desert | |
set laststatus=2 " always display a status line | |
set number " show line numbers | |
set numberwidth=5 | |
set ruler " display coordinates in status bar | |
set showcmd " display unfinished commands | |
set showmatch " show matching bracket (briefly jump) | |
set showmode " display the current mode in the status bar | |
set title " show file in titlebar | |
set scrolloff=3 " When the page starts to scroll, keep the cursor 3 lines from top/bottom | |
set cmdheight=2 " Make command line two lines high | |
" Use the same symbols as TextMate for tabstops and EOLs | |
" Show Invisibles (http://vimcasts.org/episodes/show-invisibles/) | |
set list | |
set listchars=tab:▸\ ,eol:¬ | |
highlight NonText guifg=#4a4a59 | |
highlight SpecialKey guifg=#4a4a59 | |
" md, markdown, and mk are markdown and define buffer-local preview | |
au BufRead,BufNewFile *.{md,markdown,mdown,mkd,mkdn} call s:setupMarkup() | |
" add json syntax highlighting | |
au BufNewFile,BufRead *.json set ft=javascript | |
au BufRead,BufNewFile *.txt call s:setupWrapping() | |
set wildmenu | |
set wildmode=list:longest,list:full | |
set wildignore+=*.swp,*.bak,*.o,*.obj,.git,*.rbc,*.class,.svn,vendor/gems/* |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment