DEVELOPMENT ENVIRONMENT

~liljamo/nvim-flake

ref: d49d8c3103c6a456290dfd99818a55f6fd956fd0 nvim-flake/config/plugins/tiny-code-action.nix -rw-r--r-- 970 bytes
d49d8c31Jonni Liljamo feat(lsp): enable additional Rust inlay hints 2 days ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
{pkgs, ...}: {
  extraPlugins = [
    (pkgs.vimUtils.buildVimPlugin {
      name = "tiny-code-action";
      src = pkgs.fetchFromGitHub {
        owner = "rachartier";
        repo = "tiny-code-action.nvim";
        rev = "aba93f1";
        hash = "sha256-Bp6+s4aJLQ7wK6+sVjtF65WZzP+MqVeSsHgQveVHSio=";
      };
      nvimSkipModules = [
        "tiny-code-action.previewers.snacks"
        "tiny-code-action.backend.delta"
        "tiny-code-action.backend.difftastic"
      ];
    })
  ];

  extraConfigLua = ''
    require('tiny-code-action').setup({
      picker = "telescope",
      backend = "delta",
      backend_opts = {
        delta = {
          args = {
            "--line-numbers",
            "--syntax-theme",
            "gruvbox-light"
          },
        },
      },
    })
  '';

  keymaps = [
    {
      action = "<cmd>lua require('tiny-code-action').code_action()<CR>";
      key = "<leader>ca";
      options.desc = "code action";
    }
  ];
}