Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- set ruler
- set t_Co=256
- set smartindent
- set tabstop=4 shiftwidth=4 expandtab
- set nocompatible
- set backspace=indent,eol,start
- set autoread
- set autowrite
- set wildmenu
- set showcmd
- set laststatus=2
- set copyindent
- "set cmdheight=2
- set title
- set statusline=%f%m%r%h%w\ [%n:%{&ff}/%Y]%=[0x\%04.4B][%03v][%p%%\ line\ %l\ of\ %L]
- filetype off
- set rtp+=~.vim/bundle/vundle/
- filetype plugin indent on
- syntax on
- set nu
- set autoread
- filetype plugin indent on
- set relativenumber
- call pathogen#helptags() " generate helptags for evrything in runtimepath
- execute pathogen#infect()
- "let g:kolor_italic=1 " Enable italic. Default: 1
- "let g:kolor_bold=1 " Enable bold. Default: 1
- "let g:kolor_underlined=0 " Enable underline. Default: 0
- "let g:kolor_alternative_matchparen=0 " Gray 'MatchParen' color. Default: 0
- "colorscheme kolor
- "Bundle 'davidhalter/jedi-vim'
- "YCM preview box
- autocmd FileType python setlocal completeopt-=preview
- call vundle#rc()
- Plugin 'dag/vim2hs'
- Plugin 'eagletmt/neco-ghc'
- Plugin 'gmarik/Vundle'
- Plugin 'scrooloose/nerdtree'
- Plugin 'octol/vim-cpp-enhanced-highlight'
- Plugin 'gmarik/Vundle.vim'
- "Plugin 'Shougo/neocomplete.vim'
- Plugin 'Valloric/YouCompleteMe'
- "Plugin 'klen/python-mode'
- Plugin 'Shougo/vimshell.vim'
- "call vundle#end()
- colorscheme lucius
- LuciusLight
- let g:ycm_global_ycm_extra_conf = '~/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/ycm/.ycm_extra_conf.py'
- "source ~/.vim/after/plugin/snipMate.vim
- "Tabs
- noremap <F2> :tabp <CR>
- noremap <F3> :tabn <CR>
- "Tabs
- "Copy all text
- noremap <C-e> :w <CR>
- noremap <C-y> gg"+yG<C-o>
- "Copy all text
- "abbreviation
- abbr grti template<typename T> inline T grt_i(T a,T b){ return (a%b==0)?(a/b):((a/b)+1); }
- "abbreviation
- "octave file detect
- " .m files are "octave" files
- augroup filetypedetect
- au! BufRead,BufNewFile *.m, set filetype=octave
- augroup END
- "
- " F5 executes the octave script you are editing
- autocmd FileType octave map <buffer> <f5> ggOpkg load all<esc>Gopause<esc>:w<cr>:!octave -qf %<cr>ddggdd:w<cr>
- "
- " Compile and Run
- if expand('%:e')=="cpp" " C++
- noremap <F8> :!g++ -Wall -g -D LOCAL_SYS -O2 %:t -o %:r
- noremap <F9> :!ulimit -t 2 ./%:r && ./%:r <CR>
- noremap <F7> :!g++ -Wall -g -D LOCAL_SYS -D DEBUG -O2 %:t -o %:r
- noremap <F10> :!gdb %:r <CR>
- endif
- if expand('%:e')=="cc"
- noremap <F8> :!g++ -Wall -g -O2 -D DEBUG %:t driver.cc -o %:r
- noremap <F9> :!./%:r <CR>
- endif
- if (expand('%:e'))=="c" "C
- noremap <F8> :!gcc -Wall -g -O2 %:t -o %:r <CR>
- noremap <F9> :!./%:r <CR>
- noremap <F10> :!gdb %:r <CR>
- endif
- if (expand('%:e'))=="py" " Python
- noremap <F9> :!python %:t
- endif
- if (expand('%:e'))=="hs" " Haskell
- noremap <F9> :!ghci %:t <CR>
- endif
- " End compile and run
- " Disable AutoComplPop.
- let g:acp_enableAtStartup = 0
- " Use neocomplete.
- let g:neocomplete#enable_at_startup = 1
- " " Use smartcase.
- let g:neocomplete#enable_smart_case = 1
- "Omni-Completion
- autocmd FileType python setlocal omnifunc=pythoncomplete#Complete
- nnoremap <leader>sv :source $MYVIMRC<cr>
- nnoremap <leader>ev :sp $MYVIMRC<cr>
- noremap <leader>ps <esc>:r ~/.vim/header.cpp<esc>:65<esc>
- noremap <leader>ca ggdG
- noremap <leader>g <esc>:56<esc>
- ":set pastetoggle=<f11>
- inoremap <c-u> <esc>vbUe<esc>a
- "Training Options
- noremap <Up> <NOP>
- noremap <Down> <NOP>
- noremap <Left> <NOP>
- noremap <Down> <NOP>
- noremap <leader>fn :echo expand('%')<CR>
- noremap <Esc> <NOP>
Advertisement
Add Comment
Please, Sign In to add comment