-
Notifications
You must be signed in to change notification settings - Fork 2
docs: add help text to CLI options #41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -53,8 +53,9 @@ def cli() -> None: | |||||
| "--spec", | ||||||
| required=True, | ||||||
| type=click.Path(exists=True, path_type=Path), | ||||||
| help="Path to the project spec YAML file", | ||||||
| ) | ||||||
|
Comment on lines
53
to
57
|
||||||
| @click.option("--pack", type=str, default=None) | ||||||
| @click.option("--pack", type=str, default=None, help="Name of the template pack to validate") | ||||||
| def validate(spec: Path, pack: str | None) -> None: | ||||||
| """Validate a spec (and optionally a pack manifest).""" | ||||||
| try: | ||||||
|
|
@@ -80,14 +81,16 @@ def validate(spec: Path, pack: str | None) -> None: | |||||
| "--spec", | ||||||
| required=True, | ||||||
| type=click.Path(exists=True, path_type=Path), | ||||||
| help="Path to the project spec YAML file", | ||||||
| ) | ||||||
|
Comment on lines
81
to
85
|
||||||
| @click.option("--pack", required=True, type=str) | ||||||
| @click.option("--pack", required=True, type=str, help="Name of the template pack to render") | ||||||
| @click.option( | ||||||
| "--out", | ||||||
| type=click.Path(path_type=Path), | ||||||
| default=None, | ||||||
| help="Output directory (defaults to spec name)", | ||||||
| ) | ||||||
| @click.option("--dry-run", is_flag=True, default=False) | ||||||
| @click.option("--dry-run", is_flag=True, default=False, help="Preview output without writing files") | ||||||
| @click.option("--skip-resolve", is_flag=True, default=False, help="Skip SHA resolution (offline)") | ||||||
| @click.option("--trust", is_flag=True, default=False, help="Execute hooks from manifest (unsafe)") | ||||||
| def render_cmd( | ||||||
|
|
@@ -183,12 +186,13 @@ def render_cmd( | |||||
| "--spec", | ||||||
| required=True, | ||||||
| type=click.Path(exists=True, path_type=Path), | ||||||
| help="Path to the project spec YAML file", | ||||||
| ) | ||||||
|
Comment on lines
186
to
190
|
||||||
| @click.option("--pack", required=True, type=str) | ||||||
| @click.option("--pack", required=True, type=str, help="Name of the template pack to apply") | ||||||
| @click.option( | ||||||
| "--target", required=True, type=click.Path(exists=True, file_okay=False, path_type=Path) | ||||||
| ) | ||||||
| @click.option("--dry-run", is_flag=True, default=False) | ||||||
| @click.option("--dry-run", is_flag=True, default=False, help="Preview output without writing files") | ||||||
| @click.option("--skip-resolve", is_flag=True, default=False, help="Skip SHA resolution (offline)") | ||||||
| @click.option( | ||||||
| "--trust", is_flag=True, default=False, help="Execute hooks/validations from manifest (unsafe)" | ||||||
|
|
@@ -291,8 +295,9 @@ def apply( | |||||
| "--spec", | ||||||
| required=True, | ||||||
| type=click.Path(exists=True, path_type=Path), | ||||||
| help="Path to the project spec YAML file", | ||||||
|
||||||
| help="Path to the project spec YAML file", | |
| help="Path to the project spec JSON file", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔵 LOW: Consistent and Complete CLI Help Texts Added
Confidence: 95%
Help text has now been added to all key CLI options, improving usability and self-documentation for users. This change also helps ensure argument meaning is visible via
--help, aligning with best practices for CLI tool UX.Suggestion: No action required unless further detail is desired for edge case options. Consider reviewing all remaining options to ensure similar clarity.
— Observable code is debuggable code. Consistency helps everyone (even me).