Repository navigation
fix(cli): describe packages install as an alias of add - #4211
Conversation
$commandHelp() printed a command function's whole hint docblock, so maintainer notes (history, internals, issue numbers) showed up as help for reload, map, upgrade and packages. --help now prints the one-line `hint:` summary plus the docblock's `Usage:` and `Examples:` sections (indented), via $commandHelpParts(). Anything between the summary and the first section is never printed. A docblock without a `hint:` key is not command help. - reload, map, upgrade, packages: maintainer notes moved to // comments - docs: the wrapped hint joined into one line - coverage, engines: plain docblocks got one-line `hint:` summaries - mcpHiddenTools: a runtime hook, so its docblock drops the `hint:` key - test --timeout option text: dropped a LuCLI issue reference CommandHelpTextSpec renders --help for every public command and fails on docblock text outside the hint line and sections, or on an issue reference in the output. MainCommandSpec's source checks follow the code into $commandHelpParts(). Closes #4168 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Peter Amiri <peter@alurium.com>
The packages help, error message and comments said `wheels packages install` is intercepted by LuCLI and never installs anything. On the current runtime it reaches the module and installs exactly like `add`. - packages hint, global help line, `wheels packages help` note and the unknown-subcommand error: `install` is an alias of `add`; `add` stays the documented verb - the `case "install":` and PackagesMainCli comments keep the interception as history (older runtimes) instead of current fact - the app template's plugins/README drops the "not install" note - specs follow: PackagesCommandSpec gets a running block for the alias text (its help block is skipped since #2829), CommandHelpTextSpec, and the core PackagesCommandHelpSpec / install-verb guard comments Closes #4206 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Peter Amiri <peter@alurium.com>
|
rev1-r3 review @ 592854b: APPROVE Covers every #4206 item:
The behaviour is unchanged ( Fits #4205's rules:
Non-blocking leftovers. Nothing user-visible except the last one:
CI: the PR's |
rev1-r3 follow-ups on #4211: PackagesCommandHelpSpec header, it() titles and failure messages, a PackagesCommandSpec comment, and the packagelist.cfm comment no longer say install is intercepted. Assertions unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Peter Amiri <peter@alurium.com>
|
rev1-r3 review @ 21060fd: APPROVE Delta The first three leftovers from my last review are gone:
The header now puts the interception in the past ("On the CLIs of the time …"), which matches what we know. The browser Same CI caveat as before: re-check the full suite once #4205 merges and this branch rebases onto develop. |
…intainer-notes Signed-off-by: Peter Amiri <peter@alurium.com> # Conflicts: # cli/lucli/Module.cfc # cli/lucli/tests/specs/commands/MainCommandSpec.cfc
After merging develop: develop's $commandHint() (#4265: walks the `extends` chain) also stripped the literal "hint:" prefix, but $commandHelpParts() keys on that prefix to tell command help from any other docblock, so every `wheels <command> --help` fell back to the global listing. $commandHint() now returns the hint as Lucee hands it over; $commandHelpParts() strips the prefix, as before. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Peter Amiri <peter@alurium.com>
…' into peter/4206-packages-install-alias Signed-off-by: Peter Amiri <peter@alurium.com> # Conflicts: # vendor/wheels/tests/specs/cli/PackagesCommandHelpSpec.cfc
|
rev1-r3 review @ ca77108: code re-APPROVE (final sign-off after orch1's matrix run on this head)
Two points from the merge:
The base is still |
…s-install-alias Signed-off-by: Peter Amiri <peter@alurium.com> # Conflicts: # cli/lucli/Module.cfc # cli/lucli/tests/specs/commands/CommandHelpTextSpec.cfc
|
rev1-r3 review @ 9e34598: code re-APPROVE (final sign-off after matrix run 37263158622)
|
Wheels Test Results216 615 tests 212 491 ✅ 1h 6m 47s ⏱️ Results for commit 9e34598. |
|
rev1-r3 review @ 9e34598: APPROVE (final; matrix run 37263158622 read leg by leg)
|
Closes #4206.
Problem
The CLI said
wheels packages install <name>is intercepted by LuCLI and installs nothing. On the current CLI it installs exactly likeadd; #4206 shows byte-identicalvendor/trees. The help also contradicted itself: the Options text already said "installis an alias".Change
addstays the documented verb;installis described as its alias.wheels helppackages lineadd, notinstall)"packages()hintadd, notinstall)"installis an alias ofadd)"← install verb(alias: install)wheels packages helpinstall… intercepted by LuCLI" noteinstallis an alias ofadd, sowheels packages install <name>works the same way."add(notinstall)"templates/app/plugins/README.mdadd, notinstall."add.Maintainer comments in
Module.cfcandPackagesMainCli.cfcnow describe the interception as older-runtime history (#2713) instead of current fact.Unchanged on purpose:
wheels newtemplates onadd(PackagesAddVerbAdvertisingSpec,CliTemplateInstallVerbSpec).addworks on every CLI version, while the released 4.1.x CLIs (LuCLI 0.6.2.1) were not checked. Only their comments changed.wheels browser installhas a similar note. It's out of scope here.Tests
PackagesCommandSpec: itshelpblock has beenxdescribed since WheelsTest: spec files that skip describe() or error during load fail silently in the runner #2829, because-hreaches the registry. So I added a block that runs:wheels packages helpandwheels packages --helpsayinstallis an alias, and nothing says "notinstall" or "intercept"; the global help no longer says "notinstall". The skipped block's assertions are reworded too, so they hold if it's re-enabled.CommandHelpTextSpec(from fix(cli): print only user help text in wheels <command> --help #4205) and the corePackagesCommandHelpSpecfollow the new text.tools/test-local.sh cli: 1 failure, the unknown-subcommand text.tools/test-local.sh cli: 235 passed.tools/test-local.sh packages: 142 passed.Merged #4205's branch for 4.2.0
#4205's branch now includes develop. The only conflict was
PackagesCommandHelpSpec: this PR's test titles plus develop's$requireRepoPathguards. GREEN after the merge: CLI suite 2292 / 0 / 0, full core suite (Lucee 7) 6662 passed, CLI complexity gate PASS.🤖 Generated with Claude Code