Skip to content

Commit c37d7b3

Browse files
authored
fix(flags): fix support for config.flags as a string (dmmulroy#48)
1 parent 2576637 commit c37d7b3

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

lua/tsc/init.lua

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -263,12 +263,15 @@ M.run = function()
263263
end
264264
end
265265

266+
local flags = ""
267+
if type(config.flags) == "string" then
268+
flags = config.flags
269+
else
270+
flags = utils.parse_flags(vim.tbl_extend("force", config.flags, { project = project }))
271+
end
266272
vim.schedule(function()
267273
running_processes[project] = {
268-
pid = vim.fn.jobstart(
269-
tsc .. " " .. utils.parse_flags(vim.tbl_extend("force", config.flags, { project = project })),
270-
project_opts
271-
),
274+
pid = vim.fn.jobstart(tsc .. " " .. flags, project_opts),
272275
errors = {},
273276
}
274277
end)

0 commit comments

Comments
 (0)