From e9d6b42be25ac756a7cc9c44e1a34b78919dfec2 Mon Sep 17 00:00:00 2001 From: Julian T Date: Mon, 6 Feb 2023 20:49:39 +0100 Subject: script and nvim changes --- vim-extra/.config/nvim/extra.vim | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'vim-extra') 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 {{{ -- cgit v1.2.3