summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2019-10-31 18:26:15 +0000
committerKarl Berry <karl@freefriends.org>2019-10-31 18:26:15 +0000
commitcce04847ce70fc5d8d4bc5fbfe05b3eb3b1b4bd7 (patch)
tree36a272328e041ce4e94a371c9fc6f0f79c1cb8bd /Master
parent030acc82775717c6143b3c42955d0effbbc55e75 (diff)
(setup_backup_directory, action_backup): say
"would save" instead of "saving" for dry runs. git-svn-id: svn://tug.org/texlive/trunk@52585 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rwxr-xr-xMaster/texmf-dist/scripts/texlive/tlmgr.pl12
1 files changed, 7 insertions, 5 deletions
diff --git a/Master/texmf-dist/scripts/texlive/tlmgr.pl b/Master/texmf-dist/scripts/texlive/tlmgr.pl
index 5c3e9cfeb5b..fffd185ac37 100755
--- a/Master/texmf-dist/scripts/texlive/tlmgr.pl
+++ b/Master/texmf-dist/scripts/texlive/tlmgr.pl
@@ -1887,7 +1887,8 @@ sub setup_backup_directory {
# finally, if we have --backupdir, but no --backup, just enable it
$opts{"backup"} = 1 if $opts{"backupdir"};
- info("$prg: saving backups to $opts{'backupdir'}\n")
+ my $saving_verb = $opts{"dry-run"} || $opts{"list"} ? "would save" :"saving";
+ info("$prg: $saving_verb backups to $opts{'backupdir'}\n")
if $opts{"backup"} && !$::machinereadable;
return ($ret, $autobackup);
@@ -2160,8 +2161,9 @@ sub action_backup {
# for now default to xz and allow overriding with env var
my $compressorextension = $Compressors{$::progs{'compressor'}}{'extension'};
my $tlp = $localtlpdb->get_package($pkg);
- info("saving current status of $pkg to $opts{'backupdir'}/${pkg}.r" .
- $tlp->revision . ".tar.$compressorextension\n");
+ my $saving_verb = $opts{"dry-run"} ? "would save" : "saving";
+ info("$saving_verb current status of $pkg to $opts{'backupdir'}/${pkg}.r"
+ . $tlp->revision . ".tar.$compressorextension\n");
if (!$opts{"dry-run"}) {
$tlp->make_container($::progs{'compressor'}, $localtlpdb->root,
$opts{"backupdir"}, "${pkg}.r" . $tlp->revision);
@@ -2169,7 +2171,7 @@ sub action_backup {
}
}
info("no action taken due to --dry-run\n") if $opts{"dry-run"};
- # TODO_ERRORCHECKING neets checking of the above
+ # TODO_ERRORCHECKING needs checking of the above
return ($F_OK);
}
@@ -2867,7 +2869,7 @@ sub action_update {
machine_line("-ret", $pkg, $FLAG_REVERSED_UPDATE, $rev, $mediarev, "-", "-", "-", @addargs);
} else {
if ($opts{"list"}) {
- # not issueing anything if we keep a package
+ # not issuing anything if we keep a package
upd_info($pkg, -1, $rev, $mediarevstr, "keep");
}
}