200 |
|
|
201 |
print "\n"; |
print "\n"; |
202 |
foreach my $repo ( sort keys %copy ) { |
foreach my $repo ( sort keys %copy ) { |
203 |
foreach my $rpm ( @{$copy{$repo}} ) { |
foreach my $rpm ( keys %{{ map { $_ => 1 } @{$copy{$repo}} }} ) { |
204 |
print "copying $rpm to $repo/\n"; |
print "copying $rpm to $repo/\n"; |
205 |
system(qw(cp --preserve=timestamps), $rpm, "$repo/"); |
system(qw(cp --preserve=timestamps), $rpm, "$repo/"); |
206 |
} |
} |
207 |
} |
} |
208 |
|
|
209 |
print "\n"; |
print "\n"; |
210 |
foreach my $rpm ( @remove, map { $_->{rpm}->filename } grep { $_->{repo} eq 'deleted' } @rpms ) { |
foreach my $rpm ( keys %{{ map { $_ => 1 } (@remove, map { $_->{rpm}->filename } grep { $_->{repo} eq 'deleted' } @rpms) }} ) { |
211 |
print "removing $rpm\n"; |
print "removing $rpm\n"; |
212 |
unlink $rpm; |
unlink $rpm; |
213 |
} |
} |