update
This commit is contained in:
@@ -41,9 +41,6 @@ Plug 'easymotion/vim-easymotion'
|
||||
Plug 'mattn/emmet-vim'
|
||||
Plug 'fatih/vim-go', { 'do': ':GoUpdateBinaries' }
|
||||
Plug 'pangloss/vim-javascript'
|
||||
" tagbar
|
||||
" golang install go get -u github.com/jstemmer/gotags
|
||||
Plug 'majutsushi/tagbar'
|
||||
Plug 'w0rp/ale'
|
||||
Plug 'godlygeek/tabular'
|
||||
Plug 'plasticboy/vim-markdown'
|
||||
@@ -79,6 +76,9 @@ Plug 'folke/tokyonight.nvim', { 'branch': 'main' }
|
||||
|
||||
Plug 'norcalli/nvim-colorizer.lua'
|
||||
|
||||
" code outline
|
||||
Plug 'stevearc/aerial.nvim'
|
||||
|
||||
" temp plugin
|
||||
Plug 'tpope/vim-surround'
|
||||
Plug 'buoto/gotests-vim'
|
||||
@@ -185,7 +185,6 @@ command! -bang Tabcloseright call TabCloseRight('<bang>')
|
||||
command! -bang Tabcloseleft call TabCloseLeft('<bang>')
|
||||
|
||||
" tagbar
|
||||
nmap <F8> :TagbarToggle<CR>
|
||||
nmap <F9> :%!jq .<CR>
|
||||
|
||||
" NeoComplete
|
||||
@@ -208,10 +207,14 @@ nmap <Leader>w <Plug>(easymotion-overwin-w)
|
||||
" lint
|
||||
let g:ale_linters = {
|
||||
\ 'javascript': ["{{ if .nvim.js_linter }}{{- .nvim.js_linter }}{{ else }}standard{{ end }}"],
|
||||
\ 'typescript': ["{{ if .nvim.js_linter }}{{- .nvim.js_linter }}{{ else }}standard{{ end }}"],
|
||||
\ 'go': ['gopls'],
|
||||
\ 'rust': ['analyzer'],
|
||||
\}
|
||||
let g:ale_fixers = {'javascript': ["{{ if .nvim.js_fixer }}{{- .nvim.js_fixer }}{{ else }}standard{{ end }}"]}
|
||||
let g:ale_fixers = {
|
||||
\'javascript': ["{{ if .nvim.js_fixer }}{{- .nvim.js_fixer }}{{ else }}standard{{ end }}"],
|
||||
\'typescript': ["{{ if .nvim.js_fixer }}{{- .nvim.js_fixer }}{{ else }}standard{{ end }}"],
|
||||
\}
|
||||
let g:ale_linters_explicit = 1
|
||||
let g:ale_lint_on_save = 1
|
||||
let g:ale_fix_on_save = 1
|
||||
@@ -221,33 +224,6 @@ nmap <leader>= <Plug>(ale_fix)
|
||||
let g:NERDSpaceDelims=1
|
||||
let g:NERDDefaultAlign='left'
|
||||
|
||||
let g:tagbar_type_go = {
|
||||
\ 'ctagstype' : 'go',
|
||||
\ 'kinds' : [
|
||||
\ 'p:package',
|
||||
\ 'i:imports:1',
|
||||
\ 'c:constants',
|
||||
\ 'v:variables',
|
||||
\ 't:types',
|
||||
\ 'n:interfaces',
|
||||
\ 'w:fields',
|
||||
\ 'e:embedded',
|
||||
\ 'm:methods',
|
||||
\ 'r:constructor',
|
||||
\ 'f:functions'
|
||||
\ ],
|
||||
\ 'sro' : '.',
|
||||
\ 'kind2scope' : {
|
||||
\ 't' : 'ctype',
|
||||
\ 'n' : 'ntype'
|
||||
\ },
|
||||
\ 'scope2kind' : {
|
||||
\ 'ctype' : 't',
|
||||
\ 'ntype' : 'n'
|
||||
\ },
|
||||
\ 'ctagsbin' : 'gotags',
|
||||
\ 'ctagsargs' : '-sort -silent'
|
||||
\ }
|
||||
|
||||
" copilot setup
|
||||
imap <silent><script><expr> <C-J> copilot#Accept("\<CR>")
|
||||
@@ -615,4 +591,26 @@ require'nvim-tree'.setup {
|
||||
},
|
||||
}
|
||||
|
||||
require('aerial').setup({
|
||||
-- optionally use on_attach to set keymaps when aerial has attached to a buffer
|
||||
on_attach = function(bufnr)
|
||||
-- Jump forwards/backwards with '{' and '}'
|
||||
vim.keymap.set('n', '{', '<cmd>AerialPrev<CR>', {buffer = bufnr})
|
||||
vim.keymap.set('n', '}', '<cmd>AerialNext<CR>', {buffer = bufnr})
|
||||
end,
|
||||
filter_kind = {
|
||||
"Class",
|
||||
"Constructor",
|
||||
"Enum",
|
||||
"Function",
|
||||
"Interface",
|
||||
"Module",
|
||||
"Method",
|
||||
"Struct",
|
||||
},
|
||||
close_on_select = false
|
||||
})
|
||||
-- You probably also want to set a keymap to toggle aerial
|
||||
vim.keymap.set('n', '<F8>', '<cmd>AerialToggle!<CR>')
|
||||
|
||||
EOF
|
||||
|
||||
Reference in New Issue
Block a user