updated plugins

This commit is contained in:
ManjaroOne666 2018-11-17 20:22:58 +00:00
parent a064515380
commit 309ff8f53b
1 changed files with 252 additions and 235 deletions

487
vimrc
View File

@ -9,55 +9,195 @@ endif
call plug#begin('~/.vim/bundle')
" #Activity Watch #aw-watcher-vim{{{
" https://github.com/ActivityWatch/aw-watcher-vim
Plug 'ActivityWatch/aw-watcher-vim'
"}}}
" #ALE {{{
" https://github.com/w0rp/ale
Plug 'w0rp/ale'
nnoremap <space>ne :lnext<cr>
nnoremap <space>pe :lprev<cr>
let g:ale_sign_error = '>>'
let g:ale_sign_warning = '>'
let g:ale_sign_column_always = 1
let g:ale_open_list = 0
let g:ale_linters = {'scss': ['stylelint'], 'javascript': [], 'php':['php'], 'html':['htmlhint'], 'python': [], 'vue': []}
let g:ale_html_htmlhint_options = '-c ~/.htmlhintrc --format=unix'
let g:ale_fixers = {'javascript': ['eslint']}
"}}}
" #colorV {{{
" original:
" https://github.com/gu-fan/colorv.vim
" Plug 'gu-fan/colorv.vim'
" custom fork:
" https://github.com/studio-vx/colorv.vim
Plug 'studio-vx/colorv.vim'
let g:ColorVForceGuiColors = 1
let g:colorv_no_global_map = 1
let g:colorv_win_pos = 'top'
let g:colorv_preview_area = 0
nnoremap <space>cv :ColorV<CR>
nnoremap <space>ce :ColorVEdit<CR>
nnoremap <space>cc :call ToggleColorPreview()<CR>
nnoremap <space>ci :ColorVInsert<CR>
nnoremap <space>cp :ColorVPicker<CR>
let w:colorv_is_previewing = 0
function! ToggleColorPreview() abort "{{{
if !exists('w:colorv_is_previewing')
let w:colorv_is_previewing = 0
endif
if w:colorv_is_previewing == 0
execute 'ColorVPreview'
let w:colorv_is_previewing = 1
else
execute 'ColorVClear'
let w:colorv_is_previewing = 0
endif
endfunction "}}}
"}}}
" #css3-syntax{{{
Plug 'hail2u/vim-css3-syntax'
"}}}
" #scss-syntax{{{
Plug 'cakebaker/scss-syntax.vim'
" #Ctrlp {{{
Plug 'ctrlpvim/ctrlp.vim'
" :h ctrlp-commands
" :h ctrlp-extensions
let g:ctrlp_extensions = ['tag', 'buffertag', 'quickfix', 'undo']
if executable('ag')
" Use ag in CtrlP for listing files. Lightning fast and respects .gitignore
let g:ctrlp_user_command = 'ag %s -l --nocolor -g ""'
" ag is fast enough that CtrlP doesn't need to cache
let g:ctrlp_use_caching = 0
endif
" Use ag over grep
if executable('ag')
set grepprg=ag\ --nogroup\ --nocolor\ --ignore\ node_modules
endif
"}}}
" #vim-vue {{{
" https://github.com/posva/vim-vue
Plug 'posva/vim-vue'
" #emmet-vim {{{
" https://github.com/mattn/emmet-vim
Plug 'mattn/emmet-vim'
let g:user_emmet_leader_key=',,'
let g:user_emmet_settings = {
\ 'indentation': ' ',
\}
" disable preprocessor checking for vue files - increases speed
let g:vue_disable_pre_processors=0
" set custom syntax highlighting
augroup fixhighlighting
autocmd!
autocmd BufNewFile,BufRead *.vue syntax sync fromstart
augroup END
"}}}
" #gitgutter {{{
" https://github.com/airblade/vim-gitgutter/blob/master/README.mkd
Plug 'airblade/vim-gitgutter'
" #vim-yaml
" https://github.com/stephpy/vim-yaml
Plug 'stephpy/vim-yaml'
" #python-syntax
" https://github.com/vim-python/python-syntax
Plug 'vim-python/python-syntax'
let g:python_highlight_all = 1
nmap ]h <Plug>GitGutterNextHunk
nmap [h <Plug>GitGutterPrevHunk
omap ih <Plug>GitGutterTextObjectInnerPending
omap ah <Plug>GitGutterTextObjectOuterPending
xmap ih <Plug>GitGutterTextObjectInnerVisual
xmap ah <Plug>GitGutterTextObjectOuterVisual
"}}}
" #gitv{{{
" https://github.com/gregsexton/gitv
Plug 'gregsexton/gitv'
"}}}
"#html5{{{
" https://github.com/othree/html5.vim
Plug 'othree/html5.vim'
"}}}
"#i3config.vim{{{
" https://github.com/mboughaba/i3config.vim
Plug 'mboughaba/i3config.vim'
"}}}
" #inline_edit.vim {{{
" https://github.com/AndrewRadev/inline_edit.vim
Plug 'AndrewRadev/inline_edit.vim'
let g:inline_edit_patterns = [{
\ 'main_filetype': '*html',
\ 'sub_filetype': 'scss',
\ 'indent_adjustment': 1,
\ 'start': '<style\>[^>]*lang=.scss[^>]*>',
\ 'end': '</style>'
\ }]
let g:inline_edit_autowrite = 1
let g:inline_edit_proxy_type = 'tempfile'
let g:inline_edit_new_buffer_command ='tabedit'
let g:inline_edit_modify_statusline = 0
nnoremap <space>ie :InlineEdit<cr>
"}}}
" #MatchTagAlways{{{
" https://github.com/Valloric/MatchTagAlways
Plug 'Valloric/MatchTagAlways'
"}}}
" #Netrw {{{
let g:netrw_liststyle=3
let g:netrw_list_hide='^\..*'
let g:netrw_preview = 0
"}}}
" #Obsession{{{
Plug 'tpope/vim-obsession'
"}}}
" #php.vim{{{
" https://github.com/StanAngeloff/php.vim
Plug 'StanAngeloff/php.vim'
"}}}
"#vim-json{{{
" https://github.com/elzr/vim-json
Plug 'elzr/vim-json'
" #phpcomplete.vim{{{
" https://github.com/shawncplus/phpcomplete.vim
Plug 'shawncplus/phpcomplete.vim'
" https://github.com/dsawardekar/wordpress.vim
" For up to date Wordpress Files see:
" https://github.com/joseluis/wordpress.vim-generator
"}}}
"#i3config.vim{{{
" https://github.com/mboughaba/i3config.vim
Plug 'mboughaba/i3config.vim'
" #quickscope{{{
" https://github.com/unblevable/quick-scope
Plug 'unblevable/quick-scope'
let g:qs_highlight_on_keys = ['f', 'F', 't', 'T']
"}}}
" #scss-syntax{{{
Plug 'cakebaker/scss-syntax.vim'
"}}}
" #switch {{{
"https://github.com/AndrewRadev/switch.vim
Plug 'AndrewRadev/switch.vim'
let g:switch_mapping = '<space>-'
let g:switch_custom_definitions = [
\ ['0', '1'],
\ ['ease-in', 'ease-out', 'ease-in-out', 'linear'],
\ ['auto', 'none'],
\ ['left', 'right'],
\ ['top', 'bottom'],
\ ['row', 'column'],
\ ['relative', 'absolute', 'fixed']
\ ]
"}}}
" #tagbar {{{
@ -105,42 +245,6 @@ let g:tagbar_type_vue = {
\ ]
\ }
"}}}
" #vim-surround{{{
Plug 'tpope/vim-surround'
"}}}
" #undotree {{{
Plug 'mbbill/undotree'
nnoremap <space>ut :UndotreeToggle<cr>
"}}}
" #Ctrlp {{{
Plug 'ctrlpvim/ctrlp.vim'
" :h ctrlp-commands
" :h ctrlp-extensions
let g:ctrlp_extensions = ['tag', 'buffertag', 'quickfix', 'undo']
if executable('ag')
" Use ag in CtrlP for listing files. Lightning fast and respects .gitignore
let g:ctrlp_user_command = 'ag %s -l --nocolor -g ""'
" ag is fast enough that CtrlP doesn't need to cache
let g:ctrlp_use_caching = 0
endif
" Use ag over grep
if executable('ag')
set grepprg=ag\ --nogroup\ --nocolor\ --ignore\ node_modules
endif
"}}}
" #Obsession{{{
Plug 'tpope/vim-obsession'
"}}}
" #vim-javascript{{{
Plug 'pangloss/vim-javascript'
"}}}
" #ultisnips {{{
" https://github.com/sirver/UltiSnips
@ -197,43 +301,9 @@ endfunction
set completefunc=CompleteSnippets
"}}}
" #ALE {{{
" https://github.com/w0rp/ale
Plug 'w0rp/ale'
nnoremap <space>ne :lnext<cr>
nnoremap <space>pe :lprev<cr>
let g:ale_sign_error = '>>'
let g:ale_sign_warning = '>'
let g:ale_sign_column_always = 1
let g:ale_open_list = 0
let g:ale_linters = {'scss': ['stylelint'], 'javascript': [], 'php':['php'], 'html':['htmlhint'], 'python': [], 'vue': []}
let g:ale_html_htmlhint_options = '-c ~/.htmlhintrc --format=unix'
let g:ale_fixers = {'javascript': ['eslint']}
"}}}
" #MatchTagAlways{{{
" https://github.com/Valloric/MatchTagAlways
Plug 'Valloric/MatchTagAlways'
"}}}
" #phpcomplete.vim{{{
" https://github.com/shawncplus/phpcomplete.vim
Plug 'shawncplus/phpcomplete.vim'
" https://github.com/dsawardekar/wordpress.vim
" For up to date Wordpress Files see:
" https://github.com/joseluis/wordpress.vim-generator
"}}}
" #wordpress.vim{{{
" doesn't support universal ctags
" #Plug 'dsawardekar/wordpress.vim'
" This fork does:
" https://github.com/DArcMattr/wordpress.vim/tree/universal-ctags
" Using studio-vx fork
Plug 'studio-vx/wordpress.vim', { 'branch': 'universal-ctags' }
" #undotree {{{
Plug 'mbbill/undotree'
nnoremap <space>ut :UndotreeToggle<cr>
"}}}
" #vim-commentary{{{
@ -241,24 +311,17 @@ Plug 'studio-vx/wordpress.vim', { 'branch': 'universal-ctags' }
Plug 'tpope/vim-commentary'
"}}}
" #vim-repeat{{{
" https://github.com/tpope/vim-repeat
Plug 'tpope/vim-repeat'
" #vim-dispatch{{{
" https://github.com/tpope/vim-dispatch
Plug 'tpope/vim-dispatch'
"}}}
" #emmet-vim {{{
" https://github.com/mattn/emmet-vim
Plug 'mattn/emmet-vim'
let g:user_emmet_leader_key=',,'
let g:user_emmet_settings = {
\ 'indentation': ' ',
\}
" #vim-easy-align {{{
" https://github.com/junegunn/vim-easy-align
Plug 'junegunn/vim-easy-align'
"}}}
" #vimwiki {{{
" https://github.com/vimwiki/vimwiki
Plug 'vimwiki/vimwiki'
let g:vimwiki_list = [{'path': '~/vimwiki/', 'path_html': '~/vimwiki_html/'}]
xmap ga <Plug>(EasyAlign)
nmap ga <Plug>(EasyAlign)
"}}}
" #vim-gutentags {{{
@ -269,101 +332,9 @@ let g:gutentags_ctags_tagfile = '.tags'
let g:gutentags_ctags_exclude = ['package.json', 'Session.vim', 'package-lock.json', 'TODO.txt']
"}}}
" #vim-dispatch{{{
" https://github.com/tpope/vim-dispatch
Plug 'tpope/vim-dispatch'
"}}}
" #colorV {{{
" original:
" https://github.com/gu-fan/colorv.vim
" Plug 'gu-fan/colorv.vim'
" custom fork:
" https://github.com/studio-vx/colorv.vim
Plug 'studio-vx/colorv.vim'
let g:ColorVForceGuiColors = 1
let g:colorv_no_global_map = 1
let g:colorv_win_pos = 'top'
let g:colorv_preview_area = 0
nnoremap <space>cv :ColorV<CR>
nnoremap <space>ce :ColorVEdit<CR>
nnoremap <space>cc :call ToggleColorPreview()<CR>
nnoremap <space>ci :ColorVInsert<CR>
nnoremap <space>cp :ColorVPicker<CR>
let w:colorv_is_previewing = 0
function! ToggleColorPreview() abort "{{{
if !exists('w:colorv_is_previewing')
let w:colorv_is_previewing = 0
endif
if w:colorv_is_previewing == 0
execute 'ColorVPreview'
let w:colorv_is_previewing = 1
else
execute 'ColorVClear'
let w:colorv_is_previewing = 0
endif
endfunction "}}}
"}}}
" #switch {{{
"https://github.com/AndrewRadev/switch.vim
Plug 'AndrewRadev/switch.vim'
let g:switch_mapping = '<space>-'
let g:switch_custom_definitions = [
\ ['0', '1'],
\ ['ease-in', 'ease-out', 'ease-in-out', 'linear'],
\ ['auto', 'none'],
\ ['left', 'right'],
\ ['top', 'bottom'],
\ ['row', 'column'],
\ ['relative', 'absolute', 'fixed']
\ ]
"}}}
" #gitgutter {{{
" https://github.com/airblade/vim-gitgutter/blob/master/README.mkd
Plug 'airblade/vim-gitgutter'
nmap ]h <Plug>GitGutterNextHunk
nmap [h <Plug>GitGutterPrevHunk
omap ih <Plug>GitGutterTextObjectInnerPending
omap ah <Plug>GitGutterTextObjectOuterPending
xmap ih <Plug>GitGutterTextObjectInnerVisual
xmap ah <Plug>GitGutterTextObjectOuterVisual
"}}}
" #fugitive-vim{{{
" https://github.com/tpope/vim-fugitive/blob/master/README.markdown
Plug 'tpope/vim-fugitive'
"}}}
" #vim-git{{{
" https://github.com/tpope/vim-git
Plug 'tpope/vim-git'
"}}}
" #gitv{{{
" https://github.com/gregsexton/gitv
Plug 'gregsexton/gitv'
"}}}
" #wakatime{{{
" https://wakatime.com/vim
Plug 'wakatime/vim-wakatime'
"}}}
" #vim-easy-align {{{
" https://github.com/junegunn/vim-easy-align
Plug 'junegunn/vim-easy-align'
xmap ga <Plug>(EasyAlign)
nmap ga <Plug>(EasyAlign)
"#vim-json{{{
" https://github.com/elzr/vim-json
Plug 'elzr/vim-json'
"}}}
" #vim-lsp {{{
@ -416,36 +387,75 @@ augroup User lsp_setup
augroup END
"}}}
" #inline_edit.vim {{{
" https://github.com/AndrewRadev/inline_edit.vim
Plug 'AndrewRadev/inline_edit.vim'
let g:inline_edit_patterns = [{
\ 'main_filetype': '*html',
\ 'sub_filetype': 'scss',
\ 'indent_adjustment': 1,
\ 'start': '<style\>[^>]*lang=.scss[^>]*>',
\ 'end': '</style>'
\ }]
let g:inline_edit_autowrite = 1
let g:inline_edit_proxy_type = 'tempfile'
let g:inline_edit_new_buffer_command ='tabedit'
let g:inline_edit_modify_statusline = 0
nnoremap <space>ie :InlineEdit<cr>
" #vim-repeat{{{
" https://github.com/tpope/vim-repeat
Plug 'tpope/vim-repeat'
"}}}
" #Netrw {{{
let g:netrw_liststyle=3
let g:netrw_list_hide='^\..*'
let g:netrw_preview = 0
"#vim-rsi{{{
"https://github.com/tpope/vim-rsi
Plug 'tpope/vim-rsi'
"}}}
" #Activity Watch #aw-watcher-vim{{{
" https://github.com/ActivityWatch/aw-watcher-vim
Plug 'ActivityWatch/aw-watcher-vim'
" #vim-surround{{{
Plug 'tpope/vim-surround'
"}}}
" #vim-vue {{{
" https://github.com/posva/vim-vue
Plug 'posva/vim-vue'
" disable preprocessor checking for vue files - increases speed
let g:vue_disable_pre_processors=0
" set custom syntax highlighting
augroup fixhighlighting
autocmd!
autocmd BufNewFile,BufRead *.vue syntax sync fromstart
augroup END
" #vim-yaml
" https://github.com/stephpy/vim-yaml
Plug 'stephpy/vim-yaml'
" #python-syntax
" https://github.com/vim-python/python-syntax
Plug 'vim-python/python-syntax'
let g:python_highlight_all = 1
"}}}
" #vim-javascript{{{
Plug 'pangloss/vim-javascript'
"}}}
" #vimwiki {{{
" https://github.com/vimwiki/vimwiki
Plug 'vimwiki/vimwiki'
let g:vimwiki_list = [{'path': '~/vimwiki/', 'path_html': '~/vimwiki_html/'}]
"}}}
" #wordpress.vim{{{
" doesn't support universal ctags
" #Plug 'dsawardekar/wordpress.vim'
" This fork does:
" https://github.com/DArcMattr/wordpress.vim/tree/universal-ctags
" Using studio-vx fork
Plug 'studio-vx/wordpress.vim', { 'branch': 'universal-ctags' }
"}}}
" #fugitive-vim{{{
" https://github.com/tpope/vim-fugitive/blob/master/README.markdown
Plug 'tpope/vim-fugitive'
"}}}
" #vim-git{{{
" https://github.com/tpope/vim-git
Plug 'tpope/vim-git'
"}}}
" #wakatime{{{
" https://wakatime.com/vim
Plug 'wakatime/vim-wakatime'
"}}}
call plug#end()
@ -853,6 +863,13 @@ endfunction
"}}}
"----------------------------------------------------------------------------}}}
"#commands{{{
" remove trailing whitespace
command! -range=% TrimWhitespace let b:wv = winsaveview() |
\ keeppattern <line1>,<line2>s/\s\+$// |
\ call winrestview(b:wv)
"}}}
" #settings {{{
scriptencoding utf-8
set ttyfast