Skip to content

Commit

Permalink
chore: improve cli help menu (#294)
Browse files Browse the repository at this point in the history
* chore: improve coloring

* adjust

* changes

* Create sour-tomatoes-sin.md

changeset

* fix conflicts

* use next

* use full release

* fix

* Update packages/cli/package.json
  • Loading branch information
manuel3108 authored Jan 16, 2025
1 parent f1008b7 commit 62fe0c1
Show file tree
Hide file tree
Showing 4 changed files with 58 additions and 265 deletions.
5 changes: 5 additions & 0 deletions .changeset/sour-tomatoes-sin.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"sv": patch
---

chore: improve cli help menu
2 changes: 1 addition & 1 deletion packages/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"@types/degit": "^2.8.6",
"@types/ps-tree": "^1.1.6",
"@types/tar-fs": "^2.0.4",
"commander": "^12.1.0",
"commander": "^13.0.0",
"degit": "^2.8.4",
"empathic": "^1.0.0",
"package-manager-detector": "^0.2.7",
Expand Down
8 changes: 7 additions & 1 deletion packages/cli/utils/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,13 @@ export const helpConfig: HelpConfiguration = {
}

return option.flags;
}
},
styleTitle: (str) => pc.underline(str),
styleCommandText: (str) => pc.red(str),
styleDescriptionText: (str) => pc.gray(str),
styleOptionText: (str) => pc.white(str),
styleArgumentText: (str) => pc.white(str),
styleSubcommandText: (str) => pc.red(str)
};

function formatDescription(arg: Option | Argument): string {
Expand Down
Loading

0 comments on commit 62fe0c1

Please sign in to comment.