summaryrefslogtreecommitdiff
path: root/Master/texmf
diff options
context:
space:
mode:
authorNorbert Preining <preining@logic.at>2008-05-11 09:06:02 +0000
committerNorbert Preining <preining@logic.at>2008-05-11 09:06:02 +0000
commitc5c248394d083c314affe6a7cb9c269b85be2332 (patch)
tree695148f8f25b6724f64b14842ae8c050f6a82a95 /Master/texmf
parent7e5bfeb740338e17a757fb9c8f628c64b3e2be9a (diff)
first work on rollback, needs adjustments in TLPOBJ.pm
git-svn-id: svn://tug.org/texlive/trunk@8046 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf')
-rwxr-xr-xMaster/texmf/scripts/texlive/tlmgr.pl17
1 files changed, 17 insertions, 0 deletions
diff --git a/Master/texmf/scripts/texlive/tlmgr.pl b/Master/texmf/scripts/texlive/tlmgr.pl
index c99159b7743..bb7c3bb3e62 100755
--- a/Master/texmf/scripts/texlive/tlmgr.pl
+++ b/Master/texmf/scripts/texlive/tlmgr.pl
@@ -438,9 +438,11 @@ sub action_update {
my $opt_nodepends = 0;
my $opt_dry = 0;
my $opt_all = 0;
+ my $opt_rollback;
Getopt::Long::Configure(qw(no_pass_through));
GetOptions("no-depends" => \$opt_nodepends,
"all" => \$opt_all,
+ "rollback=s" => \$opt_rollback,
"dry-run" => \$opt_dry) or pod2usage(2);
my %ret;
$tlmediasrc = TeXLive::TLMedia->new($location);
@@ -472,6 +474,21 @@ sub action_update {
# first remove the package, then reinstall it
# this way we get rid of useless files
# force the deinstallation since we will reinstall it
+ if ($opt_rollback) {
+ printf STDERR "rollback not implemented by now!!!\n";
+ if (0) {
+ if (! -d $opt_rollback) {
+ printf STDERR "rollback argument must be an existing directory!\n";
+ } else {
+ # TODO TODO TODO
+ # we need to change TLPOBJ so that it uses the same style
+ # as TLMedia with $::progs etc etc etc !!!!!!!!!!!!!!!!!
+ my $tlp = $localtlpdb->get_package($pkg);
+ $tlp->make_container("lzma", $localtlpdb->root,
+ $opt_rollback, "$pkg_" . $tlp->revision);
+ }
+ } # if 0, must be removed later
+ }
merge_into(\%ret, &remove_package($pkg, $localtlpdb, 1));
merge_into(\%ret, $tlmediasrc->install_package($pkg, $localtlpdb, $opt_nodepends, 1));
}