Skip to content

Instantly share code, notes, and snippets.

@leo-aa88
Created February 19, 2024 05:50
Show Gist options
  • Save leo-aa88/9aaabb730e4e7be18e1b8035a2246838 to your computer and use it in GitHub Desktop.
Save leo-aa88/9aaabb730e4e7be18e1b8035a2246838 to your computer and use it in GitHub Desktop.
~/.config/nvim/init.vim
call plug#begin('~/.config/nvim/plugged')
Plug 'fatih/vim-go'
Plug 'neoclide/coc.nvim', {'branch': 'release'}
Plug 'kyazdani42/nvim-tree.lua'
call plug#end()
let g:go_fmt_command = "goimports"
autocmd BufWritePre *.go :silent! GoFmt
" Navigate completion menu
inoremap <expr> <Tab> pumvisible() ? "\<C-n>" : "\<Tab>"
inoremap <expr> <S-Tab> pumvisible() ? "\<C-p>" : "\<S-Tab>"
" Confirm selection
inoremap <expr> <CR> pumvisible() ? coc#pum#confirm() : "\<CR>"
lua require'nvim-tree'.setup {}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment