diff options
-rwxr-xr-x | Master/texmf-dist/scripts/texlive/fmtutil.pl | 18 |
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 |