Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/commands/chat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@ export async function chatCommand(folderPath?: string, options: ChatOptions = {}
export function setupChatCommand(program: Command): void {
const cmd = program
.command('chat [folder-path]')
.alias('c')
.description('Chat with a replica')
.option('-r, --replica-name <name>', 'name of the replica to chat with')
.option('-m, --message <text>', 'single message for non-interactive mode')
Expand Down
1 change: 1 addition & 0 deletions src/commands/claim-key.ts
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,7 @@ export async function claimKeyCommand(options: ClaimKeyOptions): Promise<void> {
export function setupClaimKeyCommand(program: Command): void {
const cmd = program
.command('claim-key')
.alias('ck')
.description('Claim an API key using internal code')
.option('-o, --organization-name <name>', 'organization name for your account')
.option('-n, --name <name>', 'your full name')
Expand Down
1 change: 1 addition & 0 deletions src/commands/conversations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,7 @@ async function saveToFile(data: any, outputPath: string): Promise<void> {
export function setupConversationsCommand(program: Command): void {
const cmd = program
.command('conversations')
.alias('conv')
.description('Query replica conversations and mentions')
.option('-r, --replica-id <id>', 'replica ID to query conversations for')
.option('-c, --conversation-id <id>', 'specific conversation ID to query mentions')
Expand Down
1 change: 1 addition & 0 deletions src/commands/list.ts
Original file line number Diff line number Diff line change
Expand Up @@ -330,6 +330,7 @@ async function listTrainingItems(replicaId?: string): Promise<void> {
export function setupListCommand(program: Command): void {
const cmd = program
.command('list')
.alias('ls')
.description('List entities and their counts')
.option('-o, --organization <id>', 'list entities for specific organization ID')
.option('-u, --user <id>', 'list entities for specific user ID')
Expand Down
1 change: 1 addition & 0 deletions src/commands/simple-organization-setup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -420,6 +420,7 @@ export async function simpleOrganizationSetupCommand(folderPath?: string, option
export function setupSimpleOrganizationSetupCommand(program: Command): void {
const cmd = program
.command('simple-organization-setup [folder-path]')
.alias('setup')
.description('Set up user and multiple replicas with training data from subfolders')
.option('-u, --user-name <name>', 'user name for the account')
.option('-e, --user-email <email>', 'user email address')
Expand Down
5 changes: 4 additions & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,10 @@ program
// Configure help to follow wget style
program.configureHelp({
sortSubcommands: true,
subcommandTerm: (cmd) => cmd.name(),
subcommandTerm: (cmd) => {
const aliases = cmd.aliases();
return aliases.length > 0 ? `${cmd.name()}, ${aliases.join(', ')}` : cmd.name();
},
formatHelp: (cmd, helper) => {
const termWidth = helper.padWidth(cmd, helper);

Expand Down