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
Allow removing single patterns from default selection #5588
Conversation
@@ -185,11 +186,19 @@ sub run { | |||
die "looping for too long" unless ($counter--); | |||
my $needs_to_be_selected; | |||
my $ret = check_screen('on-pattern', 1); | |||
my $current_pattern = 'UNKNOWN_PATTERN'; | |||
|
|||
if ($ret) { # unneedled pattern | |||
for my $wp (keys %wanted_patterns) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we need to rename wanted_patterns to something else, as now we have unwanted patterns there as well. But I like the idea!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Renamed to %patterns
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
||
if ($ret) { # unneedled pattern | ||
for my $wp (keys %wanted_patterns) { | ||
for my $wp (keys %patterns) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
since you renamed "wanted_patterns" to "patterns" which makes perfect sense to me. Maybe you also will change "wp" to pattern ?
} | ||
|
||
my $counter = 80; | ||
while (1) { | ||
die "looping for too long" unless ($counter--); | ||
my $needs_to_be_selected; | ||
my $ret = check_screen('on-pattern', 1); | ||
my $current_pattern = 'UNKNOWN_PATTERN'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not sure that I understand purpose of this variable. Looks like you use it to detect if PATTERNS variable has at least one pattern to select and it is not default, right ?
eg. PATTERNS=default,-gnome,web
} | ||
|
||
my $counter = 80; | ||
while (1) { | ||
die "looping for too long" unless ($counter--); | ||
my $needs_to_be_selected; | ||
my $ret = check_screen('on-pattern', 1); | ||
# this variable will only be updated when the pattern list entry is under the cursor | ||
# and the pattern is in the PATTERNS variable and there is a needle for that entry |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks :)
eg.
PATTERNS=default,-gnome,web
Needed for https://progress.opensuse.org/issues/33985
Verification: http://artemis.suse.de/tests/430#step/select_patterns_and_packages/75