Repository navigation
[docs] Update aspire add command docs: exact-match requirement and interactive confirmation #1139
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
Changes from 1 commit
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 | ||||||
|---|---|---|---|---|---|---|---|---|
|
|
@@ -38,7 +38,10 @@ The following arguments are available: | |||||||
|
|
||||||||
| The name of the integration to add (for example: redis, postgres). | ||||||||
|
|
||||||||
| If a partial name or invalid name is provided, the CLI searches NuGet for approximate matches and prints them in the terminal for the user to select. If no results are found, all packages are listed. | ||||||||
| The value must exactly match either the friendly name or the full package ID (for example, `redis` or `Aspire.Hosting.Redis`). Partial or misspelled names are handled differently depending on the mode: | ||||||||
|
|
||||||||
| - **Interactive mode** (default): If the name doesn't exactly match, the CLI searches NuGet for approximate matches and prompts you to select from the results before adding. This prompt is also shown when only a single fuzzy or no-match fallback candidate is found, so a package is never silently added without your confirmation. | ||||||||
| - **Non-interactive mode** (`--non-interactive`): The command fails immediately if the name does not exactly match a friendly name or package ID. Use the exact name or full package ID to avoid errors. | ||||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Phase B critical finding — documented error is not reproducible A blind reader running this exact example today will not see the documented error. Tested on the latest publicly-installable Aspire CLIs:
Even Phase A confirms
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Deferring this to a human because the release/13.4 source at microsoft/aspire@2574ef5 contains the non-interactive exact-match guard in src/Aspire.Cli/Commands/AddCommand.cs:186-191 and the corresponding error string in src/Aspire.Cli/Resources/AddCommandStrings.resx:226-228, but the published builds cited in this thread do not exhibit that behavior. I cannot verify the first published 13.4.x build containing the guard from the source branch alone, so a maintainer should decide whether to hold the PR for the build or add a version-specific availability note.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Tagging Mitch Denny (@mitchdenny) |
||||||||
|
|
||||||||
| ## Options | ||||||||
|
|
||||||||
|
|
@@ -85,3 +88,9 @@ The following options are available: | |||||||
| ```bash title="Aspire CLI" | ||||||||
| aspire add redis --apphost './apphost.mts' | ||||||||
| ``` | ||||||||
|
|
||||||||
| - Add the **kubernetes** integration in a CI script (non-interactive mode requires the exact friendly name or package ID; partial names such as `kube` produce an error): | ||||||||
|
|
||||||||
| ```bash title="Aspire CLI" | ||||||||
| aspire add kubernetes --non-interactive | ||||||||
| ``` | ||||||||
Uh oh!
There was an error while loading. Please reload this page.