Skip to content
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

Add 'config-clear' command and fix bug in 'config-set' #411

Closed
bugfolder opened this issue Jul 29, 2024 · 1 comment · Fixed by #412
Closed

Add 'config-clear' command and fix bug in 'config-set' #411

bugfolder opened this issue Jul 29, 2024 · 1 comment · Fixed by #412

Comments

@bugfolder
Copy link
Contributor

It would be nice to have the bee config-clear file option command to clear (remove) an option from a config file.

What's the use case? Well, if you used bee config-set file option value but mistyped the name of the option, you would have created an option that you can no longer remove via bee.

Or at least that would be possible if there were not a bug in bee config-set. Although the code clearly anticipates creating a nonexistent option (the switch statement has a branch for a NULL result for $existing_type), that branch is currently unreachable. So the PR for this issue fixes that bug, as well as implementing the bee config-clear command.

And the reason I'm doing the two things together is that we need both working functions for the test code, which I've added for both functions (creating a nonexistent option, then subsequently clearing it).

@bugfolder
Copy link
Contributor Author

Although there are test fails, config-related tests are all passing, so ready for review and human testing.

@bugfolder bugfolder added pr: needs review pr: needs testing A pull request has been linked to the issue and requires testing. labels Jul 29, 2024
@yorkshire-pudding yorkshire-pudding removed pr: needs review pr: needs testing A pull request has been linked to the issue and requires testing. labels Sep 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants