summaryrefslogtreecommitdiffstats
path: root/urpm
diff options
context:
space:
mode:
Diffstat (limited to 'urpm')
-rw-r--r--urpm/get_pkgs.pm13
1 files changed, 7 insertions, 6 deletions
diff --git a/urpm/get_pkgs.pm b/urpm/get_pkgs.pm
index b2f4ad68..c1f1de0c 100644
--- a/urpm/get_pkgs.pm
+++ b/urpm/get_pkgs.pm
@@ -36,6 +36,13 @@ sub selected2list {
$file2fullnames{$pkg->filename}{$pkg->fullname} = undef;
}
+ if ($options{clean_all}) {
+ #- clean download directory, do it here even if this is not the best moment.
+ $urpm->{log}(N("cleaning %s and %s", "$urpm->{cachedir}/partial", "$urpm->{cachedir}/rpms"));
+ urpm::sys::clean_dir("$urpm->{cachedir}/partial");
+ urpm::sys::clean_dir("$urpm->{cachedir}/rpms");
+ }
+
#- examine the local repository, which is trusted (no gpg or pgp signature check but md5 is now done).
foreach my $filepath (glob("$urpm->{cachedir}/rpms/*")) {
next if -d $filepath;
@@ -56,12 +63,6 @@ sub selected2list {
}
}
- if ($options{clean_all}) {
- #- clean download directory, do it here even if this is not the best moment.
- $urpm->{log}(N("cleaning %s", "$urpm->{cachedir}/partial"));
- urpm::sys::clean_dir("$urpm->{cachedir}/partial");
- }
-
my ($error, @list_error, @list, %examined);
foreach my $medium (@{$urpm->{media} || []}) {