summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/scripts/texlive/fmtutil.pl
diff options
context:
space:
mode:
authorNorbert Preining <preining@logic.at>2015-05-04 02:00:42 +0000
committerNorbert Preining <preining@logic.at>2015-05-04 02:00:42 +0000
commit4a7e9d6a24797b82db4e502e9bee3ca8c160a6e4 (patch)
tree1d549bf4e5777b8f44f2a214b6f1eed59608c1e6 /Master/texmf-dist/scripts/texlive/fmtutil.pl
parent767c21f704c3be10018286408b1cea07622ca891 (diff)
be more relaxed with spaces in disabled formats
git-svn-id: svn://tug.org/texlive/trunk@37175 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/scripts/texlive/fmtutil.pl')
-rwxr-xr-xMaster/texmf-dist/scripts/texlive/fmtutil.pl18
1 files changed, 4 insertions, 14 deletions
diff --git a/Master/texmf-dist/scripts/texlive/fmtutil.pl b/Master/texmf-dist/scripts/texlive/fmtutil.pl
index 51584b18a4a..d7e43e338af 100755
--- a/Master/texmf-dist/scripts/texlive/fmtutil.pl
+++ b/Master/texmf-dist/scripts/texlive/fmtutil.pl
@@ -10,12 +10,6 @@
# History:
# Original shell script (C) 2001 Thomas Esser, public domain
#
-# TODO
-# not really here:
-# in main texlive, we need to ensure that the texmf-dist/web2c/fmtutil.cnf
-# file consists only of those formats that are actually installed,
-# NOT as of now of all!!
-# We are reading ALL fmtutil.cnf now!
my $TEXMFROOT;
@@ -759,14 +753,10 @@ sub read_fmtutil_file {
for (@lines) {
$i++;
chomp;
- next if /^\s*$/;
- next if /^\s*#$/;
- next if /^\s*#[^!]/;
- next if /^\s*##/;
- next if /^#![^ ]/;
- # allow for comments on the line itself
- s/([^#].*)#.*$/$1/;
- my ($a, $b, $c, @rest) = split ' ';
+ next if /^\s*#?\s*$/; # ignore empty and all-blank and just-# lines
+ next if /^\s*#[^!]/; # ignore whole-line comment that is not a disable
+ s/#[^!].*//; # remove within-line comment that is not a disable
+ my ($a, $b, $c, @rest) = split ' '; # special split rule, leading ws ign
my $disabled = 0;
if ($a eq "#!") {
# we cannot determine whether a line is a proper fmtline or