mirror of
https://github.com/Lifeforge-app/lifeforge.git
synced 2026-06-28 06:46:24 +00:00
fix(forgeCLI): enhance command usage output with colored options and commands
This commit is contained in:
@@ -62,9 +62,13 @@ export function configureHelp(program: Command): void {
|
||||
// Usage
|
||||
output.push(formatSectionTitle('Usage'))
|
||||
|
||||
const usage = helper.commandUsage(cmd)
|
||||
const usage = helper
|
||||
.commandUsage(cmd)
|
||||
.replace(/\bforge\b/, chalk.magenta('forge'))
|
||||
.replace(/\[options\]/g, chalk.green('[options]'))
|
||||
.replace(/\[command\]/g, chalk.cyan('[command]'))
|
||||
|
||||
output.push(` ${chalk.dim('$')} ${chalk.white(usage)}`)
|
||||
output.push(` ${chalk.dim('$')} ${usage}`)
|
||||
|
||||
// Description for subcommands
|
||||
if (cmd.parent && cmd.description()) {
|
||||
|
||||
Reference in New Issue
Block a user