fix(cli): use active sessionId in useLogger and improve resume robustness (#22606)

This commit is contained in:
matt korwel
2026-03-17 14:42:40 -07:00
committed by GitHub
parent 5d4e4c2814
commit e0be1b2afd
6 changed files with 136 additions and 17 deletions

View File

@@ -244,10 +244,11 @@ export async function parseArguments(
// When --resume passed without a value (`gemini --resume`): value = "" (string)
// When --resume not passed at all: this `coerce` function is not called at all, and
// `yargsInstance.argv.resume` is undefined.
if (value === '') {
const trimmed = value.trim();
if (trimmed === '') {
return RESUME_LATEST;
}
return value;
return trimmed;
},
})
.option('list-sessions', {