From 9a9eaee78557dd1c3d09882f80a8fabc19e414d0 Mon Sep 17 00:00:00 2001 From: Devon Tingley Date: Mon, 16 Aug 2021 09:04:35 -0400 Subject: [PATCH] Update .zshrc file and add nvim file --- .zshrc | 5 ----- init.vim | 43 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 43 insertions(+), 5 deletions(-) create mode 100644 init.vim diff --git a/.zshrc b/.zshrc index 723f0de..d710150 100644 --- a/.zshrc +++ b/.zshrc @@ -14,16 +14,11 @@ plugins=( sudo thefuck redis-cli - kubectl - helm golang - flutter docker - doctl docker-compose cargo rustup - ansible python yarn ) diff --git a/init.vim b/init.vim new file mode 100644 index 0000000..cba1e8a --- /dev/null +++ b/init.vim @@ -0,0 +1,43 @@ +call plug#begin('~/local/share/nvim/plugged') + Plug 'vim-airline/vim-airline' + Plug 'morhetz/gruvbox' + Plug 'preservim/nerdtree' + Plug 'Xuyuanp/nerdtree-git-plugin' + Plug 'ryanoasis/vim-devicons' + Plug 'tiagofumo/vim-nerdtree-syntax-highlight' + Plug 'neovim/nvim-lspconfig' + Plug 'hrsh7th/nvim-compe' + Plug 'windwp/nvim-autopairs' +call plug#end() + +"Theme +colorscheme gruvbox + +"General Options +set number relativenumber +set tabstop=8 softtabstop=0 expandtab shiftwidth=4 smarttab +set splitright + +"Language Servers +set completeopt=menuone,noselect "Autocomplete +let g:compe = {} +let g:compe.source = {} +let g:compe.source.nvim_lsp = v:true + +inoremap compe#complete() +inoremap compe#confirm('') +inoremap compe#close('') +inoremap compe#scroll({ 'delta': +4 }) +inoremap compe#scroll({ 'delta': -4 }) + +lua << EOF +require'lspconfig'.gopls.setup{} +require'lspconfig'.rust_analyzer.setup{} + +require('nvim-autopairs').setup({}) +require('nvim-autopairs.completion.compe').setup({ + map_cr = true, + map_complete = true, + auto_select = false, +}) +EOF