Followup from #10719 (#13243)

This commit is contained in:
bl-ue
2025-11-19 09:22:17 -07:00
committed by GitHub
parent 5c47592159
commit 0d89ac7406
4 changed files with 692 additions and 3 deletions

View File

@@ -16,6 +16,12 @@ import {
import * as fs from 'node:fs/promises';
import path from 'node:path';
/**
* Constant for the resume "latest" identifier.
* Used when --resume is passed without a value to select the most recent session.
*/
export const RESUME_LATEST = 'latest';
/**
* Session information for display and selection purposes.
*/
@@ -267,7 +273,7 @@ export class SessionSelector {
async resolveSession(resumeArg: string): Promise<SessionSelectionResult> {
let selectedSession: SessionInfo;
if (resumeArg === 'latest') {
if (resumeArg === RESUME_LATEST) {
const sessions = await this.listSessions();
if (sessions.length === 0) {