2018-07-12 13:04:00 +02:00
|
|
|
syntax on
|
|
|
|
filetype indent on
|
|
|
|
|
|
|
|
set encoding=utf-8
|
|
|
|
set clipboard=unnamed
|
2018-08-30 10:54:35 +02:00
|
|
|
set clipboard+=unnamedplus
|
2018-07-12 13:04:00 +02:00
|
|
|
set smartindent
|
|
|
|
set shiftwidth=2
|
|
|
|
set tabstop=2
|
|
|
|
set expandtab
|
|
|
|
set number
|
|
|
|
set autoread
|
2018-09-21 08:51:56 +02:00
|
|
|
set hidden
|
2018-07-12 13:04:00 +02:00
|
|
|
set background=dark
|
2018-07-12 13:15:21 +02:00
|
|
|
set rtp^=/usr/share/vim/vimfiles/
|
2018-07-12 13:04:00 +02:00
|
|
|
|
2018-10-13 11:11:46 +02:00
|
|
|
"Plugins
|
|
|
|
call plug#begin('~/.local/share/nvim/plugged')
|
|
|
|
Plug 'vim-airline/vim-airline'
|
2018-11-06 09:06:29 +01:00
|
|
|
Plug 'vim-airline/vim-airline-themes'
|
2019-02-15 14:23:02 +01:00
|
|
|
Plug 'scrooloose/nerdtree'
|
|
|
|
Plug 'scrooloose/nerdcommenter'
|
2018-11-06 09:06:29 +01:00
|
|
|
Plug 'Valloric/YouCompleteMe'
|
|
|
|
Plug 'vim-syntastic/syntastic'
|
2019-01-08 13:57:59 +01:00
|
|
|
Plug 'luochen1990/rainbow'
|
|
|
|
Plug 'numirias/semshi'
|
|
|
|
Plug 'arcticicestudio/nord-vim'
|
2019-01-23 12:04:05 +01:00
|
|
|
Plug 'ctrlpvim/ctrlp.vim'
|
|
|
|
Plug 'SirVer/ultisnips'
|
|
|
|
Plug 'honza/vim-snippets'
|
|
|
|
Plug 'jonsmithers/vim-html-template-literals'
|
|
|
|
Plug 'pangloss/vim-javascript'
|
2019-02-15 14:23:02 +01:00
|
|
|
Plug 'alvan/vim-closetag'
|
|
|
|
Plug 'shime/vim-livedown'
|
|
|
|
Plug 'w0rp/ale'
|
|
|
|
Plug 'ambv/black'
|
2018-10-13 11:11:46 +02:00
|
|
|
call plug#end()
|
|
|
|
|
2019-01-08 13:57:59 +01:00
|
|
|
colorscheme nord
|
|
|
|
|
2018-07-12 13:04:00 +02:00
|
|
|
"Airline
|
|
|
|
let g:airline#extensions#tabline#enabled = 1
|
|
|
|
let g:Powerline_symbols='unicode'
|
2019-01-09 12:47:20 +01:00
|
|
|
"let g:airline_powerline_fonts = 1
|
2019-01-08 13:57:59 +01:00
|
|
|
let g:airline_theme='nord'
|
2018-07-12 13:04:00 +02:00
|
|
|
|
2018-11-06 09:06:29 +01:00
|
|
|
"YCM
|
2019-02-15 14:23:02 +01:00
|
|
|
let mapleader = "½"
|
2019-01-08 13:57:59 +01:00
|
|
|
let g:ycm_server_python_interpreter = 'python3'
|
2018-11-06 09:06:29 +01:00
|
|
|
let g:ycm_autoclose_preview_window_after_completion=1
|
2019-01-23 12:04:05 +01:00
|
|
|
let g:ycm_min_num_of_chars_for_completion=3
|
2018-11-06 09:06:29 +01:00
|
|
|
let g:ycm_add_preview_to_completeopt = 1
|
2019-01-23 12:04:05 +01:00
|
|
|
map <leader>g :YcmCompleter GoToDefinitionElseDeclaration<CR>
|
2018-11-06 09:06:29 +01:00
|
|
|
|
|
|
|
"
|
|
|
|
let g:syntastic_python_checkers = ['python']
|
|
|
|
|
2019-01-08 13:57:59 +01:00
|
|
|
"Rainbow Parentheses
|
|
|
|
let g:rainbow_active = 1
|
|
|
|
|
2019-01-23 12:04:05 +01:00
|
|
|
" Ultisnips
|
2019-02-15 14:23:02 +01:00
|
|
|
let g:UltiSnipsExpandTrigger="<c-v>"
|
2019-01-23 12:04:05 +01:00
|
|
|
let g:UltiSnipsJumpForwardTrigger="<c-b>"
|
|
|
|
let g:UltiSnipsJumpBackwardTrigger="<c-z>"
|
|
|
|
|
2019-02-15 14:23:02 +01:00
|
|
|
" NerdTree
|
|
|
|
map <M-1> :NERDTreeToggle<CR>
|
|
|
|
let g:NERDTreeWinSize=40
|
|
|
|
let NERDTreeShowBookmarks=1
|
|
|
|
let NERDTreeMinimalUI=1
|
|
|
|
|
2019-01-23 12:04:05 +01:00
|
|
|
" HTML
|
2019-02-15 14:23:02 +01:00
|
|
|
let g:closetag_filenames = '*.html,*.js'
|
2019-01-23 12:04:05 +01:00
|
|
|
let g:html_indent_style1 = "inc"
|
|
|
|
|
2019-02-15 14:23:02 +01:00
|
|
|
" LiveDown
|
|
|
|
let g:livedown_browser = '"google-chrome-stable --new-window --app=http://localhost:1337"'
|
|
|
|
nmap gm :LivedownToggle<CR>
|
|
|
|
|
|
|
|
" Black
|
|
|
|
autocmd BufWritePre *.py execute ':Black'
|
|
|
|
|
2018-07-12 13:04:00 +02:00
|
|
|
"Mappings
|
|
|
|
:nmap <c-s> :w<CR>
|
|
|
|
:imap <c-s> <Esc>:w<CR>a
|
2018-11-06 09:06:29 +01:00
|
|
|
nnoremap <C-J> <C-W><C-J>
|
|
|
|
nnoremap <C-K> <C-W><C-K>
|
|
|
|
nnoremap <C-L> <C-W><C-L>
|
|
|
|
nnoremap <C-H> <C-W><C-H>
|
2018-07-12 13:04:00 +02:00
|
|
|
nnoremap <F7> :bp<CR>
|
|
|
|
nnoremap <F8> :bn<CR>
|
2018-11-06 09:06:29 +01:00
|
|
|
nnoremap <F9> :%!jq '.'
|
2019-02-15 14:23:02 +01:00
|
|
|
"noremap <Up> <NOP>
|
|
|
|
"noremap <Down> <NOP>
|
|
|
|
"noremap <Left> <NOP>
|
|
|
|
"noremap <Right> <NOP>
|
|
|
|
|
2018-07-12 13:04:00 +02:00
|
|
|
"AutoCommands
|
|
|
|
au BufWinEnter * set number
|
|
|
|
au FileType xml setlocal equalprg=xmllint\ --format\ --recover\ -\ 2>/dev/null
|
2018-10-17 21:06:18 +02:00
|
|
|
autocmd FileType python setlocal completeopt-=preview
|