fix: preserve argument boundaries in run command (#4979)

This commit is contained in:
Simon D'Morias
2025-12-16 12:21:51 +00:00
committed by Aiden Cline
parent 4126084dfd
commit 3f571c6117

View File

@@ -88,7 +88,9 @@ export const RunCommand = cmd({
})
},
handler: async (args) => {
let message = [...args.message, ...(args["--"] || [])].join(" ")
let message = [...args.message, ...(args["--"] || [])]
.map((arg) => (arg.includes(" ") ? `"${arg.replace(/"/g, '\\"')}"` : arg))
.join(" ")
const fileParts: any[] = []
if (args.file) {