(message: string, opts?: RunOpts)
| 249 | }) |
| 250 | |
| 251 | const runArgs = (message: string, opts?: RunOpts) => { |
| 252 | const argv: string[] = ["run"] |
| 253 | if (opts?.printLogs) argv.push("--print-logs") |
| 254 | argv.push("--model", opts?.model ?? testModelID) |
| 255 | if (opts?.agent) argv.push("--agent", opts.agent) |
| 256 | if (opts?.format) argv.push("--format", opts.format) |
| 257 | if (opts?.command) argv.push("--command", opts.command) |
| 258 | if (opts?.extraArgs) argv.push(...opts.extraArgs) |
| 259 | argv.push(message) |
| 260 | return argv |
| 261 | } |
| 262 | |
| 263 | const runOpts = (opts?: RunOpts): SpawnOpts | undefined => { |
| 264 | if (!opts?.permission) return opts |
no test coverage detected