diff options
-rwxr-xr-x | urpmi.removemedia | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/urpmi.removemedia b/urpmi.removemedia index b29e53ef..bba2131c 100755 --- a/urpmi.removemedia +++ b/urpmi.removemedia @@ -83,6 +83,12 @@ if ($options{all}) { @toremove == 0 and die N("the entry to remove is missing\n(one of %s)\n", join(", ", @entries)); $urpm->select_media({ strict_match => $options{strict_match} }, @toremove); +my $selected = 0; +foreach (@{$urpm->{media}}) { + if ($_->{modified}) { $selected = 1; last } +} $urpm->remove_selected_media; $urpm->update_media(noclean => $options{noclean}); + +exit( $selected ? 0 : 1 ); |