mirror of
https://github.com/LazyVim/LazyVim.git
synced 2025-06-21 16:39:06 +02:00
fix(dap): use dap's splitstr when running with args. Closes #4387
This commit is contained in:
parent
ee2ec7e474
commit
776994a207
1 changed files with 2 additions and 2 deletions
|
@ -6,12 +6,12 @@ local function get_args(config)
|
||||||
config = vim.deepcopy(config)
|
config = vim.deepcopy(config)
|
||||||
---@cast args string[]
|
---@cast args string[]
|
||||||
config.args = function()
|
config.args = function()
|
||||||
local new_args = vim.fn.expand(vim.fn.input("Run with args: ", args_str))
|
local new_args = vim.fn.expand(vim.fn.input("Run with args: ", args_str)) --[[@as string]]
|
||||||
if config.type and config.type == "java" then
|
if config.type and config.type == "java" then
|
||||||
---@diagnostic disable-next-line: return-type-mismatch
|
---@diagnostic disable-next-line: return-type-mismatch
|
||||||
return new_args
|
return new_args
|
||||||
end
|
end
|
||||||
return vim.split(new_args, " ")
|
return require("dap.utils").splitstr(new_args)
|
||||||
end
|
end
|
||||||
return config
|
return config
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue