Fix #2498 by dropping down hyphen to underscore in autocomplete bash script#2499
Fix #2498 by dropping down hyphen to underscore in autocomplete bash script#2499btw04 wants to merge 3 commits intoremkop:mainfrom
Conversation
|
A note on this: I tested it for the |
|
@btw04 Thank you for the PR! (Away from pc now, maybe we can store the names in a set, that may be one way to implement this...) |
|
You are right, I did not quite consider the bigger picture here. Maybe I can also think up a cleaner solution in the next couple of days. |
|
I think this should be a fairly local patch for the issue. There possibly are other issues related to this, if alias duplication is not checked in another place (i.e. if two different commands have the same subcommand), but I would argue such cases to be a different issue needing a different approach. Specifically, I think that the initial problem where two aliases are only differentiated by a hyphen might be the most common. This and similar cases should be fully resolved now. |
|
Thank you for the PR! I noticed that your proposal uses fairly recent API and language features, and I want to point out that picocli is still compiled on Java 5 (https://github.com/remkop/picocli?tab=contributing-ov-file). |
|
Thank you for your time. I must have missed that part of the contributing information, sorry! The new commit refactors it for Java 5. |
As discussed in #2498, this should probably fix the duplicate-name issue. I still think that the alias function is a duplicate which could be completely removed, but this should be an important patch nonetheless.
Please let me know if this patch no longer conforms with the intention of
bashify.