vim fixes and prettier config

This commit is contained in:
Andrejus
2020-06-06 14:25:47 +01:00
parent e998e657ce
commit 57eb54e2d5
4 changed files with 11 additions and 5 deletions

View File

@@ -4,6 +4,7 @@ neovim
net-tools
openssh-client
openssh-server
ripgrep
ruby-full
software-properties-common
tmux

View File

@@ -14,9 +14,10 @@ fi
nvim -E PlugInstall -c q
nvim -E PluginInstall -c q
sudo pip3 install neovim
sudo yarn global add neovim
sudo gen install neovim
pip3 install neovim
node --version
yarn global add neovim
sudo gem install neovim
nvim --version

View File

@@ -112,6 +112,9 @@ inoremap <silent><expr> <TAB>
"Close preview window when completion is done.
autocmd! CompleteDone * if pumvisible() == 0 | pclose | endif
" Allow use of :Prettier
command! -nargs=0 Prettier :CocCommand prettier.formatFile
" === NeoSnippet === "
" Map <C-k> as shortcut to activate snippet if available
imap <C-k> <Plug>(neosnippet_expand_or_jump)
@@ -387,10 +390,12 @@ nmap <C-l> <C-w>l
" <leader>dr - Jump to references of current symbol
" <leader>dj - Jump to implementation of current symbol
" <leader>ds - Fuzzy search current project symbols
" <leader>p - Run Prettier formatter on file
nmap <silent> <leader>dd <Plug>(coc-definition)
nmap <silent> <leader>dr <Plug>(coc-references)
nmap <silent> <leader>dj <Plug>(coc-implementation)
nnoremap <silent> <leader>ds :<C-u>CocList -I -N --top symbols<CR>
nmap <silent> <leader>p :Prettier<CR>
" === vim-better-whitespace === "
" <leader>y - Automatically remove trailing whitespace
@@ -418,7 +423,6 @@ nmap <leader>z :JsDoc<CR>
" Vim's default buffer
vnoremap <leader>p "_dP
" ============================================================================ "
" === MISC. === "
" ============================================================================ "