summaryrefslogtreecommitdiff
path: root/Master/tlpkg/bin/tl-update-keywords
diff options
context:
space:
mode:
Diffstat (limited to 'Master/tlpkg/bin/tl-update-keywords')
-rwxr-xr-xMaster/tlpkg/bin/tl-update-keywords12
1 files changed, 7 insertions, 5 deletions
diff --git a/Master/tlpkg/bin/tl-update-keywords b/Master/tlpkg/bin/tl-update-keywords
index 52de2036601..42ac24f0309 100755
--- a/Master/tlpkg/bin/tl-update-keywords
+++ b/Master/tlpkg/bin/tl-update-keywords
@@ -48,11 +48,10 @@ sub main
if (!defined($tcfile)) {
$io = \*STDIN;
} else {
- if (! -f $tcfile) {
- die "$progname: argument to --input is not a file: $!.\n";
- }
- open($io, "<", $tcfile) or die "Cannot open input file $tcfile: $!";
+ -f $tcfile || die "$progname: argument to --input is not a file: $!\n";
+ open($io, "<", $tcfile) || die "Cannot open input file $tcfile: $!";
}
+
parse_texcatalogue($io);
$Data::Dumper::Indent = 1;
@@ -60,8 +59,11 @@ sub main
if (!defined($output)) {
$out = \*STDOUT;
} else {
- open($out, ">$output") or die "Cannot open $output for writing: $!";
+ open($out, ">$output") || die "Cannot open output file $output: $!";
}
+ chomp (my $date = `LC_ALL=C date`);
+ chomp (my $progname = `basename $0`);
+ print $out "# Generated $date by $progname.\n";
print $out Data::Dumper->Dump([\%taxonomy], ["taxonomy"]), $/;
}