update dotfiles

This commit is contained in:
2026-07-08 23:01:50 +08:00
parent 1577638614
commit b4010fe910
17 changed files with 416 additions and 229 deletions
+4 -5
View File
@@ -24,7 +24,7 @@ function M.build()
local project = M.detect()
if project == "rust" then
vim.cmd("RustLsp runnables")
vim.cmd("terminal cargo build")
elseif project == "cmake" then
vim.cmd("CMakeBuild")
elseif project == "go" then
@@ -44,7 +44,7 @@ function M.run()
local project = M.detect()
if project == "rust" then
vim.cmd("RustLsp runnables")
vim.cmd("terminal cargo run")
elseif project == "cmake" then
vim.cmd("CMakeRun")
elseif project == "go" then
@@ -61,11 +61,10 @@ function M.debug()
local project = M.detect()
if project == "rust" then
vim.cmd("RustLsp debuggables")
require("dap").continue()
elseif project == "cmake" then
vim.cmd("CMakeDebug")
else
-- 通用 DAP 启动
require("dap").continue()
end
end
@@ -75,7 +74,7 @@ function M.test()
local project = M.detect()
if project == "rust" then
vim.cmd("RustLsp testables")
vim.cmd("terminal cargo test")
elseif project == "cmake" then
vim.cmd("CMakeBuild")
vim.cmd("terminal ctest --test-dir build")