Compare commits
3 Commits
84fa3b8363
...
b040eeb6f0
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b040eeb6f0 | ||
|
|
81eee03b79 | ||
|
|
8d840a4e29 |
@@ -86,13 +86,7 @@ vim.keymap.set("n", "<C-A>" ,"m'ggyG''" ,{ desc = "[Y]ank whole file" })
|
|||||||
vim.keymap.set("n", "<leader>sr" ,[[:%s/\<<C-r><C-w>\>/<C-r><C-w>/gI<Left><Left><Left>]] ,{ desc = "[S]earch/[R]eplace word under cursor" })
|
vim.keymap.set("n", "<leader>sr" ,[[:%s/\<<C-r><C-w>\>/<C-r><C-w>/gI<Left><Left><Left>]] ,{ desc = "[S]earch/[R]eplace word under cursor" })
|
||||||
|
|
||||||
-- PLUGIN KEYBINDS
|
-- PLUGIN KEYBINDS
|
||||||
vim.keymap.set({ "n", "v" } ,"<leader>ag" ,"<cmd>Antigravity<cr>" ,{ desc = "Open Antigravity" })
|
-- TODO move these to their respective plugin files (for lazy recognition)
|
||||||
vim.keymap.set({ "n", "v" } ,"<leader>aa" ,"<cmd>CodeCompanionActions<cr>" ,{ desc = "CodeCompanion - Actions" })
|
|
||||||
vim.keymap.set({ "n", "v" } ,"<leader>ac" ,"<cmd>CodeCompanionChat Toggle<cr>" ,{ desc = "CodeCompanion - Chat" })
|
|
||||||
vim.keymap.set({ "n", "v" } ,"<leader>ai" ,"<cmd>CodeCompanion<cr>" ,{ desc = "CodeCompanion - Inline" })
|
|
||||||
vim.keymap.set("v" ,"<leader>ad" ,"<cmd>CodeCompanionChat Add<cr>" ,{ desc = "CodeCompanion - Add to Chat" })
|
|
||||||
-- Expand 'cc' into 'CodeCompanion' in the command line
|
|
||||||
vim.cmd([[cab cc CodeCompanion]])
|
|
||||||
|
|
||||||
--spellcheck keybind to toggle on current buffer
|
--spellcheck keybind to toggle on current buffer
|
||||||
vim.keymap.set('n',"<leader>ze" ,"<cmd>setlocal spell<cr>" ,{ desc = "enable spellecheck on buffer" })
|
vim.keymap.set('n',"<leader>ze" ,"<cmd>setlocal spell<cr>" ,{ desc = "enable spellecheck on buffer" })
|
||||||
|
|||||||
@@ -1,13 +0,0 @@
|
|||||||
return {
|
|
||||||
"NakLast/antigravity-cli.nvim",
|
|
||||||
config = function()
|
|
||||||
require("antigravity").setup({
|
|
||||||
-- You can override the default command here if needed
|
|
||||||
cmd = "agy",
|
|
||||||
width_ratio = 0.4,
|
|
||||||
height_ratio = 0.8,
|
|
||||||
border = "rounded",
|
|
||||||
style = "vsplit",
|
|
||||||
})
|
|
||||||
end
|
|
||||||
}
|
|
||||||
@@ -1,129 +0,0 @@
|
|||||||
return {
|
|
||||||
"olimorris/codecompanion.nvim",
|
|
||||||
dependencies = {
|
|
||||||
"nvim-lua/plenary.nvim",
|
|
||||||
"nvim-treesitter/nvim-treesitter",
|
|
||||||
},
|
|
||||||
|
|
||||||
--{{{ Options
|
|
||||||
opts = {
|
|
||||||
--- {{{ Display
|
|
||||||
display = {
|
|
||||||
chat = {
|
|
||||||
window = {
|
|
||||||
layout = "vertical",
|
|
||||||
width = 0.35,
|
|
||||||
height = 0.35,
|
|
||||||
},
|
|
||||||
keymaps = {
|
|
||||||
close = {
|
|
||||||
modes = {
|
|
||||||
n = "q", -- Bind "q" in normal mode to close the chat
|
|
||||||
},
|
|
||||||
index = 1,
|
|
||||||
callback = "keymaps.close",
|
|
||||||
description = "Close Chat",
|
|
||||||
},
|
|
||||||
}
|
|
||||||
},
|
|
||||||
},
|
|
||||||
-- }}}
|
|
||||||
--
|
|
||||||
-- {{{ INTERACTIONS
|
|
||||||
interactions = {
|
|
||||||
chat = {
|
|
||||||
adapter = "ollama_coder", -- Removed the curly braces
|
|
||||||
},
|
|
||||||
inline = {
|
|
||||||
adapter = "ollama_coder", -- Removed the curly braces
|
|
||||||
},
|
|
||||||
background = {
|
|
||||||
adapter = "ollama_bg", -- Pointed this to the new extended adapter string
|
|
||||||
}
|
|
||||||
},
|
|
||||||
-- }}}
|
|
||||||
--
|
|
||||||
-- {{{ Adapters
|
|
||||||
adapters = {
|
|
||||||
http = {
|
|
||||||
gemini_pro = function()
|
|
||||||
return require("codecompanion.adapters").extend("gemini", {
|
|
||||||
name = "gemini_pro",
|
|
||||||
schema = {
|
|
||||||
model = {
|
|
||||||
default = "gemini-3.5-flash",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
end,
|
|
||||||
gemini_flash = function()
|
|
||||||
return require("codecompanion.adapters").extend("gemini", {
|
|
||||||
name = "gemini_flash",
|
|
||||||
schema = {
|
|
||||||
model = {
|
|
||||||
default = "gemini-2.0-flash",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
end,
|
|
||||||
-- local ollama coding model
|
|
||||||
ollama_coder = function()
|
|
||||||
return require("codecompanion.adapters").extend("ollama", {
|
|
||||||
name = "ollama_bg",
|
|
||||||
schema = {
|
|
||||||
model = {
|
|
||||||
default = "qwen2.5-coder:7b",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
end,
|
|
||||||
-- Added an extended Ollama adapter to fix your background task
|
|
||||||
ollama_bg = function()
|
|
||||||
return require("codecompanion.adapters").extend("ollama", {
|
|
||||||
name = "ollama_bg",
|
|
||||||
schema = {
|
|
||||||
model = {
|
|
||||||
default = "qwen3.5:4b",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
-- }}}
|
|
||||||
--
|
|
||||||
-- {{{ Library
|
|
||||||
prompt_library = {
|
|
||||||
["Local Executor"] = {
|
|
||||||
strategy = "chat",
|
|
||||||
description = "Executes implementation diffs locally and writes TDD test cases.",
|
|
||||||
opts = {
|
|
||||||
adapter = "ollama_coder", -- Force it to use your local hardware
|
|
||||||
is_default = false,
|
|
||||||
is_slash_cmd = false,
|
|
||||||
},
|
|
||||||
prompts = {
|
|
||||||
{
|
|
||||||
role = "system",
|
|
||||||
content = [[You are the Last Mile Executor.
|
|
||||||
You run in a stateless context. I will provide you with a unified diff and a testing plan.
|
|
||||||
Your strict execution order is:
|
|
||||||
1. Output the test case file modifications first (SDET-first).
|
|
||||||
2. Output the production implementation code modifications.
|
|
||||||
|
|
||||||
Do not write markdown headers (H1/H2). Use code blocks with the language ID.
|
|
||||||
Precede every code block with a line comment specifying the exact 'filepath:'.
|
|
||||||
Do not use bash syntax; adhere strictly to POSIX sh if writing shell automation.
|
|
||||||
Do not execute terminal commands directly. Output the code blocks for manual unstaged review.]],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
role = "user",
|
|
||||||
content = "I am ready to provide the Planner's diff. Await my input.",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
-- }}}
|
|
||||||
}
|
|
||||||
--}}}
|
|
||||||
}
|
|
||||||
34
lua/plugins/sidekick.lua
Normal file
34
lua/plugins/sidekick.lua
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
return {
|
||||||
|
"folke/sidekick.nvim",
|
||||||
|
keys = {
|
||||||
|
{
|
||||||
|
"<leader>as",
|
||||||
|
function()
|
||||||
|
require("sidekick.cli").select()
|
||||||
|
end,
|
||||||
|
desc = "Sidekick (Select AI CLI)",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"<leader>ak",
|
||||||
|
function()
|
||||||
|
require("sidekick.cli").toggle({ name = "antigravity", focus = true })
|
||||||
|
end,
|
||||||
|
desc = "Sidekick Toggle Antigravity",
|
||||||
|
},
|
||||||
|
{ "<leader>ap",
|
||||||
|
function()
|
||||||
|
require("sidekick.cli").prompt()
|
||||||
|
end,
|
||||||
|
desc = "Sidekick Prompt",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
opts = {
|
||||||
|
cli = {
|
||||||
|
tools = {
|
||||||
|
antigravity = {
|
||||||
|
cmd = { "agy" },
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user