added more capabilities to my nvim setup

This commit is contained in:
2026-01-19 18:45:00 -07:00
parent aa84c4997e
commit a9b956e141
18 changed files with 312 additions and 44 deletions

View File

@@ -68,3 +68,37 @@ map("n", "<leader>at", "<cmd>AvanteToggle<cr>", { desc = "AI Toggle" })
-- Database keymaps
map("n", "<leader>db", "<cmd>DBUIToggle<cr>", { desc = "Toggle DB UI" })
map("n", "<leader>da", "<cmd>DBUIAddConnection<cr>", { desc = "Add DB Connection" })
-- Neotest
local neotest = require("neotest")
map("n", "<leader>tt", neotest.run.run, { desc = "Run nearest test" })
map("n", "<leader>tf", function()
neotest.run.run(vim.fn.expand("%"))
end, { desc = "Run test file" })
map("n", "<leader>ts", neotest.summary.toggle)
map("n", "<leader>to", neotest.output.open)
map("n", "<leader>tc", "<cmd>Coverage<cr>", { desc = "Show coverage" })
-- Go benchmark
map("n", "<leader>gb", function()
vim.cmd("!go test -bench . ./...")
end, { desc = "Go benchmarks" })
map("n", "<leader>gp", function()
vim.cmd("!go test -cpuprofile cpu.out && go tool pprof cpu.out")
end, { desc = "Go CPU profile" })
-- Overseer
map("n", "<leader>or", "<cmd>OverseerRun<cr>", { desc = "Run task" })
map("n", "<leader>ot", "<cmd>OverseerToogle<cr>", { desc = "Task list" })
-- Aerial
map("n", "<leader>so", "<cmd>AerialToggle<cr>", { desc = "Symbols outline" })
map("n", "<leader>sh", vim.lsp.buf.incoming_calls, { desc = "Incoming calls" })
map("n", "<leader>sc", vim.lsp.buf.outgoing_calls, { desc = "Outgoing calls" })
-- Diagnostics
map("n", "<leader>xx", "<cmd>Trouble diagnostics toggle<cr>")
map("n", "<leader>xw", "<cmd>Trouble workspace_diagnostics<cr>")
map("n", "<leader>xt", "<cmd>Trouble todo<cr>")