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

Set local flags for each command #45

Merged
merged 1 commit into from
Sep 25, 2024

Conversation

NamelessOne91
Copy link
Contributor

@NamelessOne91 NamelessOne91 commented Sep 25, 2024

Related to https://github.com/SUSE/spacewalk/issues/25285

All flags were being set as global flags belonging to the RootCmd, resulting in help messages displaying all flags even though they were not actually in use by the specific command.

This PR addresses the issue by defining flags that are only meaningful for a command VS global (parent inherited) flags.

The parsing of the configuration .yaml file is also postponed to the actual moment it is needed by the sub-commands.

@NamelessOne91 NamelessOne91 self-assigned this Sep 25, 2024
@NamelessOne91 NamelessOne91 merged commit 679d99f into uyuni-project:master Sep 25, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants