|
- syntax on
- filetype plugin indent on
- set ai
- set number
- set mouse=a
- "set breakindent
- set encoding=utf-8 "Added this for vim-hug
- set nu rnu
- set hidden
- set tabstop=4
- set shiftwidth=4
- runtime ftplugin/man.vim
- set keywordprg=:Man
- let mapleader = "s"
- set is
-
- "Colour settings
- set t_Co=256 "Use 256 colours (Use this setting only if your terminal supports 256 colours)
- set tgc "More terminal colours
- let &t_8f = "\<Esc>[38;2;%lu;%lu;%lum"
- let &t_8b = "\<Esc>[48;2;%lu;%lu;%lum"
- let base16colorspace=256
- colorscheme base16-ocean
- "colorscheme Tomorrow-Night
-
- "Pymode stuff
- let g:pymode_folding = 0
-
- "Easymotion prefix
- map <Leader> <Plug>(easymotion-prefix)
-
- " turn hybrid line numbers off
- ":set nonumber norelativenumber
- ":set nonu nornu
-
- " toggle hybrid line numbers
- ":set number! relativenumber!
- ":set nu! rnu!
-
- "Triggers for number toggling
- :augroup numbertoggle
- : autocmd!
- : autocmd BufEnter,FocusGained,InsertLeave * set relativenumber
- : autocmd BufLeave,FocusLost,InsertEnter * set norelativenumber
- :augroup END
-
- "CtrlP bindings
- nmap <leader>d :CtrlPBuffer<cr>
- nmap <leader>a :CtrlPMRU<cr>
- nmap <leader>l :CtrlPLine<cr>
-
- "NERDTree bingings
- nnoremap <F1> :NERDTreeToggle<cr>
- nnoremap <leader>t :NERDTreeToggle<cr>
- nnoremap <F2> :NERDTreeFocus<cr>
- "autocmd vimenter * NERDTree
-
-
- "Buffergator bindings
- nmap <leader>[ :BuffergatorMruCyclePrev<cr>
- nmap <leader>] :BuffergatorMruCycleNext<cr>
- nmap <leader>f :BuffergatorOpen<cr>
- let g:buffergator_autoexpand_on_split=0
-
- "Stuff for faster movement and aesthetics
- :set cursorline
- nnoremap <F3> :tabprevious<cr>
- nnoremap <F4> :tabnext<cr>
- nnoremap <F5> :buffers<CR>:buffer<Space>
- noremap <BS> <PageUp>
- noremap <Space> <PageDown>
- noremap <leader>o o<Esc>k
- nmap <leader>p <C-w><C-r>
- noremap <leader>y <C-W>w
- noremap <C-h> <C-W>h
- noremap <C-l> <C-W>l
- noremap <C-j> <C-W>j
- noremap <C-k> <C-W>k
- nnoremap <leader>z :wa<cr>
- nnoremap - :w<cr>
- set so=10
-
- "Copy and pasting
- vmap <C-c> "+y
- nmap <S-y> "+p
-
- set guioptions-=m "menu bar
- set guioptions-=T "toolbar
- set guicursor+=a:blinkon0 "Remove weird blinking cursor
- "set guioptions-=r "scrollbar
- nmap <leader>T :vsplit <BAR> :wincmd l <BAR> :enew <cr>
- "nmap <leader>bq :bp <BAR> bd #<cr>
- nmap <leader>:ob :OpenBookmark<cr>
- let g:deoplete#enable_at_startup = 1 "Enables deoplete
- autocmd FileType python setlocal completeopt-=preview "Romoves docwindow for Jedi-vim
-
- "Omnisharp taken from the ReadMe I think
- let g:OmniSharp_timeout = 5
- set completeopt=longest,menuone,preview
- set previewheight=5
- let g:ale_linters = { 'cs': ['OmniSharp'] }
- let g:OmniSharp_highlight_types = 1
- augroup omnisharp_commands autocmd!
-
- " air-line
- let g:airline_theme='tomorrow'
- let g:airline#extensions#tabline#enabled = 1
- let g:airline#extensions#tabline#tab_nr_type = 1
- let g:airline#extensions#tabline#show_tab_nr = 1
- let g:airline#extensions#tabline#buffer_nr_show = 1
- let g:airline#extensions#tabline#formatter = 'default'
- let g:airline#extensions#tabline#buffer_nr_show = 1
- let g:airline#extensions#tabline#fnametruncate = 16
- let g:airline#extensions#tabline#fnamecollapse = 2
-
- "let mapleader=","
-
- let g:airline#extensions#tabline#buffer_idx_mode = 1
-
- nmap ,1 <Plug>AirlineSelectTab1
- nmap ,2 <Plug>AirlineSelectTab2
- nmap ,3 <Plug>AirlineSelectTab3
- nmap ,4 <Plug>AirlineSelectTab4
- nmap ,5 <Plug>AirlineSelectTab5
- nmap ,6 <Plug>AirlineSelectTab6
- nmap ,7 <Plug>AirlineSelectTab7
- nmap ,8 <Plug>AirlineSelectTab8
- nmap ,9 <Plug>AirlineSelectTab9
-
- let g:airline_powerline_fonts = 1
-
- if !exists('g:airline_symbols')
- let g:airline_symbols = {}
- endif
-
- " unicode symbols
- let g:airline_left_sep = '»'
- let g:airline_left_sep = '▶'
- let g:airline_right_sep = '«'
- let g:airline_right_sep = '◀'
- let g:airline_symbols.linenr = '␊'
- let g:airline_symbols.linenr = ''
- let g:airline_symbols.linenr = '¶'
- let g:airline_symbols.branch = '⎇'
- let g:airline_symbols.paste = 'ρ'
- let g:airline_symbols.paste = 'Þ'
- let g:airline_symbols.paste = '∥'
- let g:airline_symbols.whitespace = 'Ξ'
-
- " airline symbols
- let g:airline_left_sep = ''
- let g:airline_left_alt_sep = ''
- let g:airline_right_sep = ''
- let g:airline_right_alt_sep = ''
- let g:airline_symbols.branch = ''
- let g:airline_symbols.readonly = ''
- let g:airline_symbols.linenr = ''
-
- "Folding
- nnoremap <leader>6 :setlocal fdm=indent<cr>
- nnoremap <leader>7 :setlocal fdm=marker<cr>
- nnoremap <leader>8 :setlocal fdm=expr<cr>:set foldexpr=getline(v:lnum)=~'^\\s*$'&&getline(v:lnum+1)=~'\\S'?'<1':1<cr>
- set foldmethod=indent
- set foldlevelstart=1
- autocmd FileType vim setlocal foldmethod=marker
- autocmd FileType '' setlocal fdm=expr foldexpr=getline(v:lnum)=~'^\\s*$'&&getline(v:lnum+1)=~'\\S'?'<1':1
-
- let javaScript_fold=1 " JavaScript
- let perl_fold=1 " Perl
- let php_folding=1 " PHP
- let r_syntax_folding=1 " R
- let ruby_fold=1 " Ruby
- let sh_fold_enabled=1 " sh
- let vimsyn_folding='af' " Vim script
- let xml_syntax_folding=1 " XML
-
- "ctrlp and buffgator custom stuff
- let g:ctrlp_custom_ignore = {
- \ 'dir': '\v[\/](\.(git|hg|svn)|\_site)$',
- \ 'file': '\v\.(exe|so|dll|class|png|jpg|jpeg)$',
- \}
- let g:ctrlp_working_path_mode = 'r' " Use the nearest .git directory as the cwd
- let g:buffergator_viewport_split_policy = 'R' " Use the right side of the screen
- let g:buffergator_suppress_keymaps = 1 " I want my own keymappings...
|