diff --git a/skills/device-pod-cli/assets/device-host-cli.mjs b/skills/device-pod-cli/assets/device-host-cli.mjs index ed0466b4..af4494a8 100644 --- a/skills/device-pod-cli/assets/device-host-cli.mjs +++ b/skills/device-pod-cli/assets/device-host-cli.mjs @@ -1966,14 +1966,15 @@ async function main() { if (sub === 'start') return startJob('keil-build', parseArgs(rest.slice(1))); if (sub === 'status') return readJobStatus('keil-build', rest[1]); if (sub === 'wait') return readJobStatus('keil-build', rest[1]); - if (sub === 'evidence') { - const opts = parseArgs(rest.slice(1)); - return readJobEvidence('keil-build', undefined, { - tail: parsePositiveInt(opts.tail, 200), - full: opts.full === true || opts.full === 'true', - target: opts.target - }); - } + } + if (command === 'evidence') { + const sub = rest[0] || 'build'; + const opts = parseArgs(rest.slice(1)); + return readJobEvidence(sub === 'download' ? 'keil-download' : 'keil-build', rest[1], { + tail: parsePositiveInt(opts.tail, 200), + full: opts.full === true || opts.full === 'true', + target: opts.target + }); } } if (group === 'debug-probe') { @@ -1985,14 +1986,14 @@ async function main() { const sub = rest[0] || 'start'; if (sub === 'start') return startJob('keil-download', parseArgs(rest.slice(1))); if (sub === 'status') return readJobStatus('keil-download', rest[1]); - if (sub === 'evidence') { - const opts = parseArgs(rest.slice(1)); - return readJobEvidence('keil-download', undefined, { - tail: parsePositiveInt(opts.tail, 200), - full: opts.full === true || opts.full === 'true', - target: opts.target - }); - } + } + if (command === 'evidence') { + const opts = parseArgs(rest.slice(1)); + return readJobEvidence('keil-download', rest[1], { + tail: parsePositiveInt(opts.tail, 200), + full: opts.full === true || opts.full === 'true', + target: opts.target + }); } if (command === 'reset') return await resetRun(); if (command === 'launch-flash') return await launchFlash(parseArgs(rest));