Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/georgesalkhouri/nvim-aider
🤖 Seamlessly integrate Aider with Neovim for an enhanced AI-assisted coding experience!
https://github.com/georgesalkhouri/nvim-aider
ai-coding aider lua neovim neovim-plugin terminal-integration
Last synced: about 2 months ago
JSON representation
🤖 Seamlessly integrate Aider with Neovim for an enhanced AI-assisted coding experience!
- Host: GitHub
- URL: https://github.com/georgesalkhouri/nvim-aider
- Owner: GeorgesAlkhouri
- License: mit
- Created: 2024-11-19T17:58:02.000Z (about 2 months ago)
- Default Branch: main
- Last Pushed: 2024-11-26T20:03:45.000Z (about 2 months ago)
- Last Synced: 2024-11-26T20:31:56.725Z (about 2 months ago)
- Topics: ai-coding, aider, lua, neovim, neovim-plugin, terminal-integration
- Language: Lua
- Homepage:
- Size: 56.6 KB
- Stars: 20
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# [![aider](https://avatars.githubusercontent.com/u/172139148?s=20&v=4)](https://aider.chat) nvim-aider
🤖 Seamlessly integrate Aider with Neovim for an enhanced AI-assisted coding experience!
![screenshot_1](https://github.com/user-attachments/assets/5d779f73-5441-4d24-8cce-e6dfdc5bf787)
![scrennshot_2](https://github.com/user-attachments/assets/6e8c3ed4-84d8-49bb-9aba-7d81323864d8)> 🚧 This plugin is in initial development. Expect breaking changes and rough edges.
> _October 17, 2024_## 🌟 Features
- [x] 🖥️ Aider terminal integration within Neovim
- [x] 🎨 Color theme configuration support with auto Catppuccin flavor synchronization
if available
- [x] 📤 Quick commands to add/drop current buffer files
- [x] 📤 Send buffers or selections to Aider
- [x] 💬 Optional user prompt for buffer and selection sends
- [x] 🔍 Aider command selection UI with fuzzy search and input prompt## 🎮 Commands
- ⌨️ `AiderTerminalToggle` - Toggle the Aider terminal window
- 📤 `AiderTerminalSend [text]` - Send text to Aider
- Without arguments: Opens input prompt
- With arguments: Sends provided text directly
- In visual mode: Sends selected text with an optional prompt
- 🔍 `AiderQuickSendCommand` - List all Aider commands in telescope picker
with option to add prompt after selection
- 📁 `AiderQuickAddFile` - Add current buffer file to Aider session
- 🗑️ `AiderQuickDropFile` - Remove current buffer file from Aider session
- 📋 `AiderQuickSendBuffer` - Send entire buffer content to Aider
with an optional prompt## 🔗 Requirements
🐍 Python: Install `aider`
📋 System: **Neovim** >= 0.9.4, Working clipboard
🌙 Lua: `folke/snacks.nvim`, `nvim-telescope/telescope.nvim`,
_optionals_ `catppuccin/nvim`> Note: 📎 This plugin requires a working system clipboard as
> it sends text to the terminal via Aider's /paste commands,
> which inserts the system clipboard register for the best compatibility.## 📦 Installation
Using lazy.nvim:
```lua
{
"GeorgesAlkhouri/nvim-aider",
cmd = {
"AiderTerminalToggle",
},
keys = {
{ "a/", "AiderTerminalToggle", desc = "Open Aider" },
{ "as", "AiderTerminalSend", desc = "Send to Aider", mode = { "n", "v" } },
{ "ac", "AiderQuickSendCommand", desc = "Send Command To Aider" },
{ "ab", "AiderQuickSendBuffer", desc = "Send Buffer To Aider" },
{ "a+", "AiderQuickAddFile", desc = "Add File to Aider" },
{ "a-", "AiderQuickDropFile", desc = "Drop File from Aider" },
},
dependencies = {
"folke/snacks.nvim",
"nvim-telescope/telescope.nvim",
--- The below dependencies are optional
"catppuccin/nvim",
},
config = true,
}
```## ⚙️ Configuration
There is no need to call setup if you don't want to change the default options.
```lua
require("nvim_aider").setup({
-- Command line arguments passed to aider
args = {
"--no-auto-commits",
"--pretty",
"--stream",
},-- Theme colors (automatically uses Catppuccin flavor if available)
theme = {
user_input_color = "#a6da95",
tool_output_color = "#8aadf4",
tool_error_color = "#ed8796",
tool_warning_color = "#eed49f",
assistant_output_color = "#c6a0f6",
completion_menu_color = "#cad3f5",
completion_menu_bg_color = "#24273a",
completion_menu_current_color = "#181926",
completion_menu_current_bg_color = "#f4dbd6",
},-- Other snacks.terminal.Opts options
config = {
os = { editPreset = "nvim-remote" },
gui = { nerdFontsVersion = "3" },
},win = {
style = "nvim_aider",
position = "bottom",
},
})
```---