Skip to content

Commit

Permalink
fix(command): directly print example text w/o capitalization (#741)
Browse files Browse the repository at this point in the history
Co-authored-by: Steffen Trog <steffen.trog@fastleansmart.com>
  • Loading branch information
KnorpelSenf and Steffen Trog authored Sep 16, 2024
1 parent 33b01f8 commit b0f1942
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions command/help/_help_generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ export class HelpGenerator {
}
return this.label("Examples") +
Table.from(examples.map((example: Example) => [
dim(bold(`${capitalize(example.name)}:`)),
dim(bold(example.name)),
dedent(example.description),
]))
.padding(1)
Expand Down Expand Up @@ -358,10 +358,6 @@ export class HelpGenerator {
}
}

function capitalize(string: string): string {
return string.charAt(0).toUpperCase() + string.slice(1);
}

/**
* Colorize arguments string.
* @param argsDefinition Arguments definition: `<color1:string> <color2:string>`
Expand Down

0 comments on commit b0f1942

Please sign in to comment.