From a90336c3069c198b41b7b6eb76e3389610ad5eb7 Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Wed, 14 Feb 2024 03:01:19 +0000 Subject: CTAN sync 202402140301 --- support/texlogfilter/README | 8 +++-- support/texlogfilter/texlogfilter | 18 ++++++++---- support/texlogfilter/texlogfilter.html | 53 ++++++++++++++++++---------------- 3 files changed, 46 insertions(+), 33 deletions(-) (limited to 'support/texlogfilter') diff --git a/support/texlogfilter/README b/support/texlogfilter/README index d7d707ab5a..e8ceb46dc5 100644 --- a/support/texlogfilter/README +++ b/support/texlogfilter/README @@ -69,9 +69,13 @@ texlogfilter 1.1 HISTORY - * 2022, march, version 1.1 : add --info and --no-info options. + * 2024, February, version 1.2 : fix duplicate or missing lines; handle + package and class names with hyphen ; add info and warning patterns + for fonts. - * 2021, november, version 1.0 : initial version. + * 2022, March, version 1.1 : add --info and --no-info options. + + * 2021, November, version 1.0 : initial version. DOCUMENTATION The documentation is integrated, writtent in Plain Old Documentation diff --git a/support/texlogfilter/texlogfilter b/support/texlogfilter/texlogfilter index f960c9a377..6a8b246232 100755 --- a/support/texlogfilter/texlogfilter +++ b/support/texlogfilter/texlogfilter @@ -16,7 +16,7 @@ use Getopt::Long; use Term::ANSIColor; my $name = "texlogfilter"; -my $version = "1.1"; +my $version = "1.2"; # options my @userfilters; @@ -192,7 +192,7 @@ while (<>) { # try to show usefull lines following some warnings or errors (starting with # whitespaces or package name) if ($currentpackage ne ""){ - if (/(s+|\($currentpackage\))/){print $_;} + if (/^(\s{2}|\($currentpackage\))/){$nextlines = 1;} else {$currentpackage = ""; } } @@ -200,7 +200,7 @@ while (<>) { if ($nextlines > 0) { $nextlines--; print $_; } # find errors - elsif (/^(!\s+|.*?:\d+:\s+)?(Class|Package) (\w+ )?Error/i) { if ($3){$currentpackage=$3} handle_error(0, "nofilename"); } + elsif (/^(!\s+|.*?:\d+:\s+)?(Class|Package)\s+(\S+)?\s*Error/i) { if ($3){$currentpackage=$3}; handle_error(0, "nofilename"); } elsif (/^(!\s+)?LaTeX (?:Error)/i) { handle_error(); } elsif (/^(!|.*?:\d+:) Undefined control sequence\./i) { chomp; handle_error(4); } elsif (/^(!|.*?:\d+:) Use of (.*) doesn't match its definition\./i) { handle_error(3); } @@ -209,13 +209,16 @@ while (<>) { elsif (/^No pages of output/i) { handle_error(); } # find warning - elsif (/^(!\s+)?(Class|Package) (\w+ )?Warning/i) { if ($3){$currentpackage=$3} handle_warning(0, "nofilename"); } + elsif (/^(!\s+)?(Class|Package)\s+(\S+)?\s*Warning/i) { if ($3){$currentpackage=$3}; handle_warning(0, "nofilename"); } elsif (/^(!\s+)?(LaTeX|\* LaTeX) Warning: (Citation|Reference)/i) { if ($showrefmsg) {handle_warning();} } + elsif (/^(!\s+)?(LaTeX|\* LaTeX) Font Warning/i) { $currentpackage="Font"; handle_warning(); } elsif (/^(!\s+)?(LaTeX|\* LaTeX) Warning/i) { handle_warning(); } elsif (/Runaway argument\?/i) { handle_warning(1); } elsif (/(overfull|underfull|badbox)/i) { if ($showboxmsg){handle_warning(1);} } # find infos + elsif (/^(!\s+)?(Class|Package)\s+(\S+)?\s*Info/i) { if ($showinfomsg){ if ($3){$currentpackage=$3}; handle_info(); } } + elsif (/^(!\s+)?(LaTeX|\* LaTeX) Font Info/i) { if ($showinfomsg){ $currentpackage="Font"; handle_info(); } } elsif (/^(LaTeX) (\w+ )?Info/i) { if ($showinfomsg){handle_info();} } elsif (/^(LaTeX)/i) { handle_info(); } elsif (/^Document Class/i) { handle_info(); } @@ -338,9 +341,12 @@ distributions of LaTeX version 2005/12/01 or later. =over -=item * 2022, march, version 1.1 : add --info and --no-info options. +=item * 2024, February, version 1.2 : fix duplicate or missing lines; handle +package and class names with hyphen ; add info and warning patterns for fonts. -=item * 2021, november, version 1.0 : initial version. +=item * 2022, March, version 1.1 : add --info and --no-info options. + +=item * 2021, November, version 1.0 : initial version. =back diff --git a/support/texlogfilter/texlogfilter.html b/support/texlogfilter/texlogfilter.html index 6cebc68729..789edcbc84 100644 --- a/support/texlogfilter/texlogfilter.html +++ b/support/texlogfilter/texlogfilter.html @@ -19,7 +19,7 @@

SYNOPSIS

-
    texlogfilter [options] file.log
+
texlogfilter [options] file.log

DESCRIPTION

@@ -27,39 +27,39 @@

Without input file, standard input is used. Use on latex engine output with:

-
    latex file.tex < /dev/null | texlogfilter
+
latex file.tex < /dev/null | texlogfilter

OPTIONS

-
    --help                 : print this help and exit
-    --version              : print version and exit
+
--help                 : print this help and exit
+--version              : print version and exit
 
-    --box                  : show box warnings
-    --no-box               : mask box warnings
+--box                  : show box warnings
+--no-box               : mask box warnings
 
-    --ref                  : show reference/citation warnings
-    --no-ref               : mask reference/citation warnings
+--ref                  : show reference/citation warnings
+--no-ref               : mask reference/citation warnings
 
-    --info                 : show latex info messages
-    --no-info              : mask latex info messages
+--info                 : show latex info messages
+--no-info              : mask latex info messages
 
-    --filename             : print current file name
-    --no-filename          : do not print current file name
-    --files-ext=string     : regex pattern used to match files extension (default: tex|sty|cls|bib)
+--filename             : print current file name
+--no-filename          : do not print current file name
+--files-ext=string     : regex pattern used to match files extension (default: tex|sty|cls|bib)
 
-    --skips                : indicate skipped lines
-    --no-skips             : mask skipped lines
-    --skip-marker=string   : marker used to indicate skipped lines (defaut: ...)
+--skips                : indicate skipped lines
+--no-skips             : mask skipped lines
+--skip-marker=string   : marker used to indicate skipped lines (defaut: ...)
 
-    --add-filter=string    : add user filter pattern (as perl regular expression)
+--add-filter=string    : add user filter pattern (as perl regular expression)
 
-    --full-log             : show full log (don't filter - only colorize latex engine output)
+--full-log             : show full log (don't filter - only colorize latex engine output)
 
-    --errors-color=string
-    --warnings-color=string
-    --infos-color=string
-    --skips-color=string
-    --user-color=string    : colors used for errors, warnings, informations and skipped lines
+--errors-color=string +--warnings-color=string +--infos-color=string +--skips-color=string +--user-color=string : colors used for errors, warnings, informations and skipped lines

ALTERNATIVES

@@ -94,10 +94,13 @@ -- cgit v1.2.3