#2131: improve auto completion for ide upgrade mode#2164
Conversation
Add enum value completion for `ide upgrade --mode` and keep the implementation local to `UpgradeModeProperty`.
Preserve `--mode=` in shell completion so `ide upgrade --mode` can offer enum value suggestions correctly.
Coverage Report for CI Build 29421588719Warning No base build found for commit Coverage: 72.212%Details
Uncovered ChangesNo uncovered changes found. Coverage RegressionsRequires a base build to compare against. How to fix this → Coverage Stats💛 - Coveralls |
| This can cause that the auto-completion of versions can take a few seconds sometimes. | ||
| However, we implemented a smart caching mechanism so we do not call `git pull` again if already done a minute ago. | ||
|
|
||
| The auto-completion also supports argument values. |
There was a problem hiding this comment.
As someone reading this for the first time, I would assume, that argument values are supported everywhere within ide .... If this is in fact true, it's fine.
In case, there are still places, auto-completion for argument values are not implemented yet, this could cause confusion or bug reports and should be changed.
There was a problem hiding this comment.
Agreed 😃. I’ll refine the wording slightly so it’s less likely to be misinterpreted.
|
Please also change the title of this PR to follow the rules of DoD:
|
…ch, and no-match behavior of upgrade mode completion.

This PR fixes #2131
Implemented changes:
EnumProperty--modeinUpgradeCommandlet--mode=s)--key=value)Testing instructions
Ensure the newly built executable is picked up (restart shell if needed).
Expected output:
--mode=snapshot --mode=stable --mode=unstableThe suggested values correspond to all predefined values of the UpgradeMode enum.
Expected output:
--mode=snapshot --mode=stableExpected output: the command is automatically completed with the matched value.
ide upgrade --mode=stableChecklist for this PR
Make sure everything is checked before merging this PR. For further info please also see
our DoD.
mvn clean testlocally all tests pass and build is successful#«issue-id»: «brief summary»(e.g.#921: fixed setup.bat). If no issue ID exists, title only.In Progressand assigned to you or there is no issue (might happen for very small PRs)with
internal