From fd47dacdb6dcc3b4bad80b28f82ee19f045c7256 Mon Sep 17 00:00:00 2001 From: Adam Byczkowski Date: Tue, 11 Aug 2026 21:53:28 -0600 Subject: [PATCH 1/2] fix: correct truncated help text for schema load/check commands Click's default short-help truncates at 45 chars when no explicit short_help is set, cutting "load" and "check" mid-sentence in the `infrahubctl schema` command list. Set explicit short_help strings so the generated docs read as complete sentences. --- docs/docs/infrahubctl/infrahubctl-schema.mdx | 4 ++-- infrahub_sdk/ctl/schema.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/docs/infrahubctl/infrahubctl-schema.mdx b/docs/docs/infrahubctl/infrahubctl-schema.mdx index 2bab8a77c..34f46844a 100644 --- a/docs/docs/infrahubctl/infrahubctl-schema.mdx +++ b/docs/docs/infrahubctl/infrahubctl-schema.mdx @@ -16,8 +16,8 @@ $ infrahubctl schema [OPTIONS] COMMAND [ARGS]... **Commands**: -* `load`: Load one or multiple schema files into... -* `check`: Check if schema files are valid and what... +* `load`: Load one or multiple schema files into Infrahub. +* `check`: Check if schema files are valid and their impact on Infrahub. * `export`: Export the schema from Infrahub as YAML... * `list`: List all available schema kinds. * `show`: Show details for a specific schema kind. diff --git a/infrahub_sdk/ctl/schema.py b/infrahub_sdk/ctl/schema.py index 21f9c7a98..f3d42afea 100644 --- a/infrahub_sdk/ctl/schema.py +++ b/infrahub_sdk/ctl/schema.py @@ -175,7 +175,7 @@ def get_node( return None -@app.command() +@app.command(short_help="Load one or multiple schema files into Infrahub.") @catch_exception(console=console) async def load( schemas: list[Path], @@ -227,7 +227,7 @@ async def load( await asyncio.sleep(delay=1) -@app.command() +@app.command(short_help="Check if schema files are valid and their impact on Infrahub.") @catch_exception(console=console) async def check( schemas: list[Path], From 402c25553e00efabdaa79b0b95d1a56aa5147dc4 Mon Sep 17 00:00:00 2001 From: Adam Byczkowski Date: Tue, 11 Aug 2026 21:54:29 -0600 Subject: [PATCH 2/2] docs: add changelog entry for schema CLI help fix --- changelog/+schema-cli-short-help.fixed.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 changelog/+schema-cli-short-help.fixed.md diff --git a/changelog/+schema-cli-short-help.fixed.md b/changelog/+schema-cli-short-help.fixed.md new file mode 100644 index 000000000..830263dcd --- /dev/null +++ b/changelog/+schema-cli-short-help.fixed.md @@ -0,0 +1 @@ +Fixed the `load` and `check` command descriptions in the `infrahubctl schema` help output and generated docs, which were cut off mid-sentence.