-
Notifications
You must be signed in to change notification settings - Fork 242
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
crc config get
returns an error code when the setting has a default value
#3678
Comments
2.18.0 and 2.10.0 both have the same behaviour, so if this is a regression it's not a recent one. |
Lines 30 to 32 in 2468363
|
This seems to be an inconsistency. Defaults are not an error IMNSHO ;-) |
@cfergeau I think back then it was less obvious. It wouldn't have happened if you did this I think.
|
It is maybe not a regression, but an inconsistency; it makes no sense to error out when it is the default |
`crc config get xxx` prints: ``` Configuration property 'xxx' is not set. Default value is 'yyy' ``` when its value is not set, but the command exit code is 1. Since '1' is returned for errors (`crc config get invalid-prop`), this is not the correct exit code. This commit changes it to 0, which is the same as successful `crc config get` calls when the value is not the default one. This fixes crc-org#3678
`crc config get xxx` prints: ``` Configuration property 'xxx' is not set. Default value is 'yyy' ``` when its value is not set, but the command exit code is 1. Since '1' is returned for errors (`crc config get invalid-prop`), this is not the correct exit code. This commit changes it to 0, which is the same as successful `crc config get` calls when the value is not the default one. This fixes #3678
The text was updated successfully, but these errors were encountered: