From bbe50638e74d39df437470a5ea81e5b7d91363c5 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Wed, 2 Jul 2008 13:33:10 +0000 Subject: doc tweaks. git-svn-id: svn://tug.org/texlive/trunk@9154 c570f23f-e606-0410-a88d-b1316a301751 --- Master/tlpkg/bin/tl-update-containers | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) (limited to 'Master/tlpkg/bin/tl-update-containers') diff --git a/Master/tlpkg/bin/tl-update-containers b/Master/tlpkg/bin/tl-update-containers index caa47470a16..ffda46f7373 100755 --- a/Master/tlpkg/bin/tl-update-containers +++ b/Master/tlpkg/bin/tl-update-containers @@ -31,11 +31,10 @@ my $opt_force = 0; my $help = 0; TeXLive::TLUtils::process_logging_options(); - GetOptions( + "force" => \$opt_force, "location=s" => \$opt_location, "recreate" => \$opt_recreate, - "force" => \$opt_force, "help|?" => \$help) or pod2usage(1); pod2usage(-exitstatus => 0, -verbose => 2) if $help; @@ -69,10 +68,13 @@ sub main my $opt_containerdir = "$opt_location/$TeXLive::TLConfig::NetArchive"; my %count; my $nettlpdb; + if ($opt_recreate) { + # remake everything. @todopacks = $tlpdb->list_packages(); $nettlpdb = $tlpdb->copy; $nettlpdb->root($opt_location); + } else { $nettlpdb = TeXLive::TLPDB->new(root => $opt_location); if (!defined($nettlpdb)) { @@ -197,20 +199,21 @@ sub main `rm $opt_containerdir/$op.*`; $count{"removed"}++; } - if (@todopacks) { + + if (@todopacks && ! $opt_recreate) { # we updated something print "$0: $count{new} new, $count{removed} removed, " . "$count{updated} updated, $count{unchanged} unchanged.\n"; - # Finally we copy the source tlpdb over to the destination tlpdb } else { print "$0: nothing to be done.\n"; } - # STRANGE: It seems that calling -recreate did somehow not safe the + + # STRANGE: It seems that calling -recreate did not save the # docfiles into the texlive.tlpdb, no idea why. So update should now - # do that + # do that. $nettlpdb->save; system("lzma --force -k -z $opt_location/tlpkg/texlive.tlpdb"); - # + # do a last check that all the containers are actually present foreach my $p ($tlpdb->list_packages) { next if $p =~ /00texlive.*\./; @@ -235,7 +238,7 @@ tl-update-containers [OPTION]... =over 8 -=item B<-containerdir> I +=item B<-location> I The location to find the previously generated containers; default is C<./tlpkg>. If this is changed so that the containers appear in a different directory on the net, then you need to also -- cgit v1.2.3