mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-02-28 09:23:08 +08:00
feat: update usage recommendations across multiple workflow commands to require user confirmation and improve clarity
This commit is contained in:
@@ -11,6 +11,7 @@ interface ServeOptions {
|
||||
host?: string;
|
||||
browser?: boolean;
|
||||
frontend?: 'js' | 'react' | 'both';
|
||||
new?: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -20,7 +21,8 @@ interface ServeOptions {
|
||||
export async function serveCommand(options: ServeOptions): Promise<void> {
|
||||
const port = Number(options.port) || 3456;
|
||||
const host = options.host || '127.0.0.1';
|
||||
const frontend = options.frontend || 'js';
|
||||
// --new flag is shorthand for --frontend react
|
||||
const frontend = options.new ? 'react' : (options.frontend || 'js');
|
||||
|
||||
// Validate project path
|
||||
let initialPath = process.cwd();
|
||||
|
||||
@@ -10,6 +10,7 @@ interface ViewOptions {
|
||||
host?: string;
|
||||
browser?: boolean;
|
||||
frontend?: 'js' | 'react' | 'both';
|
||||
new?: boolean;
|
||||
}
|
||||
|
||||
interface SwitchWorkspaceResult {
|
||||
@@ -76,7 +77,8 @@ export async function viewCommand(options: ViewOptions): Promise<void> {
|
||||
const port = Number(options.port) || 3456;
|
||||
const host = options.host || '127.0.0.1';
|
||||
const browserHost = host === '0.0.0.0' || host === '::' ? 'localhost' : host;
|
||||
const frontend = options.frontend || 'both';
|
||||
// --new flag is shorthand for --frontend react
|
||||
const frontend = options.new ? 'react' : (options.frontend || 'both');
|
||||
|
||||
// Resolve workspace path
|
||||
let workspacePath = process.cwd();
|
||||
|
||||
Reference in New Issue
Block a user