From 0f80c99739f06a39588bcde452d36ba58d986bc3 Mon Sep 17 00:00:00 2001 From: Alex Auvolat Date: Wed, 3 May 2023 16:53:06 +0200 Subject: Add rust-analyzer coc vim plugin --- nixpkgs/common.nix | 13 ++++++++++++- vim/vimrc | 3 +++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/nixpkgs/common.nix b/nixpkgs/common.nix index f3cc2a9..1f98b2e 100644 --- a/nixpkgs/common.nix +++ b/nixpkgs/common.nix @@ -1,5 +1,8 @@ { pkgs, ... }: { home.username = "lx"; + home.packages = with pkgs; [ + nodejs-slim + ]; programs.direnv = { enable = true; @@ -22,7 +25,15 @@ programs.vim = { enable = true; extraConfig = (builtins.readFile ../vim/vimrc); - plugins = with pkgs.vimPlugins; [ vim-nix fzf-vim nerdtree vim-go ]; + plugins = with pkgs.vimPlugins; [ + vim-nix + fzf-vim + nerdtree + vim-go + coc-nvim + coc-json + coc-rust-analyzer + ]; }; programs.git.enable = true; diff --git a/vim/vimrc b/vim/vimrc index 8ea1315..743e081 100644 --- a/vim/vimrc +++ b/vim/vimrc @@ -16,6 +16,9 @@ map ; :FZF nnoremap l :bnext nnoremap k :bprev +" S-D for prev/next Coc diagnostic +nnoremap d (coc-diagnostic-next-error) +nnoremap s (coc-diagnostic-prev-error) " Append modeline after last line in buffer. -- cgit v1.2.3