rework: open_float_terminal uses table instead of string

fix: all languages now use proper terminal setup
This commit is contained in:
DarthMooMancer
2025-05-12 08:43:42 -04:00
parent 4ddbe07a30
commit a2c43661c4
8 changed files with 55 additions and 130 deletions
+2 -1
View File
@@ -42,6 +42,7 @@ function M.init_git(path, gitignore_lines)
end
end
---@param cmd table
function M.open_float_terminal(cmd)
local presets = require("Polydev.presets")
local presets_opts = presets.getPresets(M.opts.preset)
@@ -73,7 +74,7 @@ function M.open_float_terminal(cmd)
end
end
vim.fn.termopen(cmd)
vim.fn.termopen(table.concat(cmd, "/"))
vim.api.nvim_buf_set_keymap(buf, "n", "<ESC>", "i<C-\\><C-n>:q<CR>", { noremap = true, silent = true })
return buf, win
end