feat(prompt_logger): Save prompts to disk and add buffer navigation via keymaps (#2075)

This commit is contained in:
hamidi-dev
2025-06-22 19:20:03 +02:00
committed by GitHub
parent a0fc91d4c8
commit 7daf169228
5 changed files with 133 additions and 0 deletions

View File

@@ -391,6 +391,19 @@ _See [config.lua#L9](./lua/avante/config.lua) for the full config_
-- auto_approve_tool_permissions = true, -- Auto-approve all tools (no prompts)
-- auto_approve_tool_permissions = {"bash", "replace_in_file"}, -- Auto-approve specific tools only
},
prompt_logger = { -- logs prompts to disk (timestamped, for replay/debugging)
enabled = true, -- toggle logging entirely
log_dir = vim.fn.stdpath("cache") .. "/avante_prompts", -- directory where logs are saved
fortune_cookie_on_success = false, -- shows a random fortune after each logged prompt (requires `fortune` installed)
next_prompt = {
normal = "<C-n>", -- load the next (newer) prompt log in normal mode
insert = "<C-n>",
},
prev_prompt = {
normal = "<C-p>", -- load the previous (older) prompt log in normal mode
insert = "<C-p>",
},
},
mappings = {
--- @class AvanteConflictMappings
diff = {