summaryrefslogtreecommitdiff
path: root/Master/tlpkg
diff options
context:
space:
mode:
authorPiotr Strzelczyk <piotr@eps.gda.pl>2011-06-24 13:44:20 +0000
committerPiotr Strzelczyk <piotr@eps.gda.pl>2011-06-24 13:44:20 +0000
commit2931b682a1a4cedaba5b396fd098d5f91897aaf6 (patch)
treeb248fb0c545e31351e353078d91e23b0aadfb49c /Master/tlpkg
parente0f675d582fd007b94da94e98c85da00d2acf491 (diff)
fix due to change in media detection logic
git-svn-id: svn://tug.org/texlive/trunk@23125 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg')
-rw-r--r--Master/tlpkg/archive/download-package-repository19
1 files changed, 13 insertions, 6 deletions
diff --git a/Master/tlpkg/archive/download-package-repository b/Master/tlpkg/archive/download-package-repository
index f2a9b057f35..5a400957d40 100644
--- a/Master/tlpkg/archive/download-package-repository
+++ b/Master/tlpkg/archive/download-package-repository
@@ -71,19 +71,21 @@ sub main {
}
info("Cloning package repository from $location\n");
+
$::archivedir = "__ARCHIVE__";
- if (-d "$::localrepo/$Archive") {
- rename("$::localrepo/$Archive", "$::localrepo/$::archivedir") ||
- die "unable to rename $::localrepo/$Archive to $::archivedir: $!";
+ if (-d "$::localrepo/$::archivedir") {
+ rename("$::localrepo/$::archivedir", "$::localrepo/$Archive") ||
+ die "unable to rename $::localrepo/$::archivedir to $Archive: $!";
}
- if (!-d "$::localrepo/$::archivedir") {
- mkdir("$::localrepo/$::archivedir") ||
- die "$0: could not create directory $::localrepo/$::archivedir: $!";
+ if (!-d "$::localrepo/$Archive") {
+ mkdir("$::localrepo/$Archive") ||
+ die "$0: could not create directory $::localrepo/$Archive: $!";
}
if (!-d "$::localrepo/$InfraLocation" ) {
mkdir("$::localrepo/$InfraLocation") ||
die "$0: cannot create directory $::localrepo/$InfraLocation: $!";
}
+
my $tlpdbfile = "$InfraLocation/$DatabaseName";
my $tlpdbpacked = "$tlpdbfile.$DefaultContainerFormat";
my $md5there;
@@ -109,6 +111,11 @@ sub main {
die "unusable repository database at $location\n";
}
+ if (-d "$::localrepo/$Archive") {
+ rename("$::localrepo/$Archive", "$::localrepo/$::archivedir") ||
+ die "unable to rename $::localrepo/$Archive to $::archivedir: $!";
+ }
+
my $error_count = 0;
for my $pkgname ($tlpdb->list_packages) {
next if $pkgname =~ /^00texlive/;