summaryrefslogtreecommitdiff
path: root/vim-extra/.config/nvim
diff options
context:
space:
mode:
authorJulian T <julian@jtle.dk>2023-02-06 20:49:39 +0100
committerJulian T <julian@jtle.dk>2023-02-06 21:33:19 +0100
commite9d6b42be25ac756a7cc9c44e1a34b78919dfec2 (patch)
tree808ad9196a06f4ebe23eb846b908c22a879c61e5 /vim-extra/.config/nvim
parentc2de43acb0fe7e54d5d394cd4a9c9c8b00f7e41c (diff)
script and nvim changes
Diffstat (limited to 'vim-extra/.config/nvim')
-rw-r--r--vim-extra/.config/nvim/extra.vim16
1 files changed, 16 insertions, 0 deletions
diff --git a/vim-extra/.config/nvim/extra.vim b/vim-extra/.config/nvim/extra.vim
index fee2a0b..104b041 100644
--- a/vim-extra/.config/nvim/extra.vim
+++ b/vim-extra/.config/nvim/extra.vim
@@ -30,6 +30,22 @@
autocmd CompleteDone * pclose
colorscheme PaperColor
+
+ lua << EOF
+ local on_attach = function(client, bufnr)
+ vim.api.nvim_buf_set_option(bufnr, 'omnifunc', 'v:lua.vim.lsp.omnifunc')
+ local bufopts = { noremap=true, silent=true, buffer=bufnr }
+ vim.keymap.set('n', 'K', vim.lsp.buf.hover, bufopts)
+ end
+
+ require('lspconfig')['rust_analyzer'].setup{
+ on_attach = on_attach,
+ settings = {
+ ["rust-analyzer"] = {}
+ }
+ }
+
+EOF
"}}}
" Latex {{{