Copied c.lua as cpp.lua

This commit is contained in:
DarthMooMancer
2025-04-07 11:14:54 -04:00
parent c77958a9ae
commit 886a409faf
2 changed files with 199 additions and 1 deletions
+3 -1
View File
@@ -173,7 +173,9 @@ end
function M.build()
local root = M.get_project_root()
if not root then return print("Error: Project root not found.") end
local cmd = "cd " .. root .. "/build && cmake .. --preset default" .. " && cmake --build ."
local build_dir = root .. "/build"
local cmd = "cd " .. build_dir .. " && cmake .. --preset default" .. " && cmake --build ."
local term_buf = M.open_float_terminal(cmd)
vim.api.nvim_buf_set_option(term_buf, "modifiable", true)
local output = vim.fn.system(cmd)