summaryrefslogtreecommitdiff
path: root/neovim/.config/nvim/lua/plugins/aider.lua
blob: 709c00b89de27b5f9ded0910944f1f949d55eed4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
return {
  {
    "ddzero2c/aider.nvim",
    config = function()
      require("aider").setup({
        command = 'aider',   -- Path to aider command
        model = 'ollama_chat/qwen2.5',    -- AI model to use
        mode = 'diff',       -- Edit mode: 'diff' or 'inline'
        -- Floating window options
        float_opts = {
          relative = 'editor',
          width = 0.8,      -- 80% of editor width
          height = 0.8,     -- 80% of editor height
          style = 'minimal',
          border = 'rounded',
          title = ' Aider ',
          title_pos = 'center',
        },
      })
      vim.keymap.set({ 'v', 'n' }, 'ga', ':AiderEdit<CR>', { noremap = true, silent = true })
    end
  }
}