Default Value in CLI Showing Incorrectly
See original GitHub issueI have the specified custom symbol:
"StyleCop": {
"type": "parameter",
"datatype": "bool",
"description": "Adds and enforces StyleCop analysers. NOTE: You may need to sort using statements if you enable this due to limitations in the dotnet new templating engine.",
"defaultValue": "false"
},
However, when I check the help menu in the CLI using dotnet new api --help
, I see that it looks like the default is true because it has a star beside it.
This was reported to me as a bug in https://github.com/Dotnet-Boxed/Templates/issues/758.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:8 (5 by maintainers)
Top Results From Across the Web
Incorrect default value · Issue #1733 · remkop/picocli
The test provided shows that, under certain conditions, incorrect clearing of command option values occurs. test2 fails because after test1 ...
Read more >Compilation error with default command line argument value
As I try to take a command line argument of type uint64, when I am setting default value to a valid unsigned 64...
Read more >awk - Why is my command giving wrong output?
I m trying to output lines if col 1 has digit value , but its not working. My sample file doesn't have digit...
Read more >Troubleshoot AWS CLI errors - AWS Command Line Interface
Diagnose and fix common AWS Command Line Interface (AWS CLI) errors. ... Check your command for spelling and formatting errors.
Read more >How can I reset $PATH to its default value in Ubuntu?
The answer to your question is: PATH=$(getconf PATH). and works on any POSIX compliant system. The selected answer is the correct way to ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
As was agreed with PM, I fixed the help message such that for normal behavior of the boolean switch no unnecessary/confusing information is shown. If and only if the “default if the option is without value” is unusual, the more verbose message will be shown.
These having different defaults feels wrong:
Let’s get Posix experts to weigh in on how common this is in the non-Windows world. From a Windows world, this made me cry.
I’d like to put this on the backlog for 5.0.200 so we have time to think through the behavior and how we want to express this.
@jonsequitur