From 887efa406957bb88f0dfdfe12732b1ac0e1cfae1 Mon Sep 17 00:00:00 2001 From: Tam Nhu Tran Date: Thu, 12 Feb 2026 07:59:39 +0700 Subject: [PATCH] fix(cursor): show auto-detect error message, add subcommand sync comment --- src/ccs.ts | 1 + src/commands/cursor-command.ts | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/ccs.ts b/src/ccs.ts index 0161870c..8d3a7f2e 100644 --- a/src/ccs.ts +++ b/src/ccs.ts @@ -536,6 +536,7 @@ async function main(): Promise { // Only route to command handler for known subcommands, otherwise treat as profile // Note: Bare `ccs cursor` shows help (unlike copilot which falls through to profile) // This is intentional — cursor has no profile-switching mode + // Keep in sync with cursor-command.ts switch cases const CURSOR_SUBCOMMANDS = ['auth', 'status', 'models', 'start', 'stop', 'help', '--help', '-h']; if (firstArg === 'cursor' && (args.length === 1 || CURSOR_SUBCOMMANDS.includes(args[1]))) { // `ccs cursor ` - route to cursor command handler diff --git a/src/commands/cursor-command.ts b/src/commands/cursor-command.ts index 99cd7551..1ae9c4df 100644 --- a/src/commands/cursor-command.ts +++ b/src/commands/cursor-command.ts @@ -107,7 +107,11 @@ async function handleAuth(): Promise { // Fall back to manual import console.log(''); - console.log('Auto-detection failed. Please provide credentials manually.'); + if (autoResult.error) { + console.log(`Auto-detection failed: ${autoResult.error}`); + } else { + console.log('Auto-detection failed. Please provide credentials manually.'); + } console.log(''); console.log('To find your Cursor credentials:'); console.log(' 1. Open Cursor IDE');