diff options
-rwxr-xr-x | Build/source/texk/texlive/linked_scripts/latexindent/latexindent.pl | 2 | ||||
-rwxr-xr-x | Master/bin/windows/latexindent.exe | bin | 8705120 -> 8705316 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/support/latexindent/README | 2 | ||||
-rw-r--r-- | Master/texmf-dist/doc/support/latexindent/latexindent-yaml-schema.json | 2 | ||||
-rw-r--r-- | Master/texmf-dist/doc/support/latexindent/latexindent.pdf | bin | 1250364 -> 1250154 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/support/latexindent/latexindent.tex | 18 | ||||
-rw-r--r-- | Master/texmf-dist/scripts/latexindent/LatexIndent/Version.pm | 4 | ||||
-rw-r--r-- | Master/texmf-dist/scripts/latexindent/LatexIndent/Wrap.pm | 16 | ||||
-rwxr-xr-x | Master/texmf-dist/scripts/latexindent/defaultSettings.yaml | 2 | ||||
-rwxr-xr-x | Master/texmf-dist/scripts/latexindent/latexindent.pl | 2 |
10 files changed, 28 insertions, 20 deletions
diff --git a/Build/source/texk/texlive/linked_scripts/latexindent/latexindent.pl b/Build/source/texk/texlive/linked_scripts/latexindent/latexindent.pl index 5dacf0bc84d..a4cf71ab954 100755 --- a/Build/source/texk/texlive/linked_scripts/latexindent/latexindent.pl +++ b/Build/source/texk/texlive/linked_scripts/latexindent/latexindent.pl @@ -1,6 +1,6 @@ #!/usr/bin/env perl # -# latexindent.pl, version 3.22, 2023-06-01 +# latexindent.pl, version 3.22.1, 2023-07-02 # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by diff --git a/Master/bin/windows/latexindent.exe b/Master/bin/windows/latexindent.exe Binary files differindex 9ab10107dc2..a10d2409708 100755 --- a/Master/bin/windows/latexindent.exe +++ b/Master/bin/windows/latexindent.exe diff --git a/Master/texmf-dist/doc/support/latexindent/README b/Master/texmf-dist/doc/support/latexindent/README index df74dc160cb..5bda1fba77a 100644 --- a/Master/texmf-dist/doc/support/latexindent/README +++ b/Master/texmf-dist/doc/support/latexindent/README @@ -1,5 +1,5 @@ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - latexindent.pl, version 3.22, 2023-06-01 + latexindent.pl, version 3.22.1, 2023-07-02 PERL script to indent code within environments, and align delimited environments in .tex files. diff --git a/Master/texmf-dist/doc/support/latexindent/latexindent-yaml-schema.json b/Master/texmf-dist/doc/support/latexindent/latexindent-yaml-schema.json index cf707723a9c..003c26d5454 100644 --- a/Master/texmf-dist/doc/support/latexindent/latexindent-yaml-schema.json +++ b/Master/texmf-dist/doc/support/latexindent/latexindent-yaml-schema.json @@ -2,7 +2,7 @@ "$schema": "http://json-schema.org/schema", "$id": "latexindent-yaml-schema.json", "title": "latexindent.pl YAML schema", - "description": "latexindent.pl YAML schema helper, V3.22 2023-06-01", + "description": "latexindent.pl YAML schema helper, V3.22.1 2023-07-02", "type": "object", "properties": { "fileExtensionPreference": { diff --git a/Master/texmf-dist/doc/support/latexindent/latexindent.pdf b/Master/texmf-dist/doc/support/latexindent/latexindent.pdf Binary files differindex fb04afb06c6..b8e3cab83b9 100644 --- a/Master/texmf-dist/doc/support/latexindent/latexindent.pdf +++ b/Master/texmf-dist/doc/support/latexindent/latexindent.pdf diff --git a/Master/texmf-dist/doc/support/latexindent/latexindent.tex b/Master/texmf-dist/doc/support/latexindent/latexindent.tex index 70c2be9805f..b74e1eee32d 100644 --- a/Master/texmf-dist/doc/support/latexindent/latexindent.tex +++ b/Master/texmf-dist/doc/support/latexindent/latexindent.tex @@ -1093,15 +1093,15 @@ perl latexindent-module-installer.pl % \begin{latexonly} You will occasionally see dates shown in the margin (for example, next to this - paragraph!) \announce{2017-06-25}{announce} which detail the date of the version in which - the feature was implemented; the `N' stands for `new as of the date shown' and `U' stands - for `updated as of the date shown'. If you see \stardemo, it means that the feature is - either new (N) or updated (U) as of the release of the current version; if you see - \stardemo\, attached to a listing, then it means that listing is new (N) or updated (U) - as of the current version. If you have not read this document before (and even if you - have!), then you can ignore every occurrence of the \stardemo; they are simply there to - highlight new and updated features. The new and updated features in this documentation - (\gitRel) are on the following pages: \listOfNewFeatures% % \end{latexonly} + paragraph!) \announce{2017-06-25}{announce} which detail the date of the version in + which the feature was implemented; the `N' stands for `new as of the date shown' and `U' + stands for `updated as of the date shown'. If you see \stardemo, it means that the + feature is either new (N) or updated (U) as of the release of the current version; if + you see \stardemo\, attached to a listing, then it means that listing is new (N) or + updated (U) as of the current version. If you have not read this document before (and + even if you have!), then you can ignore every occurrence of the \stardemo; they are + simply there to highlight new and updated features. The new and updated features in this + documentation (\gitRel) are on the following pages: \listOfNewFeatures% % \end{latexonly} \subsection{A word about regular expressions} \index{regular expressions!a word about} diff --git a/Master/texmf-dist/scripts/latexindent/LatexIndent/Version.pm b/Master/texmf-dist/scripts/latexindent/LatexIndent/Version.pm index f7ed57cf8d9..ae69bb7928d 100644 --- a/Master/texmf-dist/scripts/latexindent/LatexIndent/Version.pm +++ b/Master/texmf-dist/scripts/latexindent/LatexIndent/Version.pm @@ -20,6 +20,6 @@ use warnings; use Exporter qw/import/; our @EXPORT_OK = qw/$versionNumber $versionDate/; -our $versionNumber = '3.22'; -our $versionDate = '2023-06-01'; +our $versionNumber = '3.22.1'; +our $versionDate = '2023-07-02'; 1 diff --git a/Master/texmf-dist/scripts/latexindent/LatexIndent/Wrap.pm b/Master/texmf-dist/scripts/latexindent/LatexIndent/Wrap.pm index dc99170452f..c600d28e188 100644 --- a/Master/texmf-dist/scripts/latexindent/LatexIndent/Wrap.pm +++ b/Master/texmf-dist/scripts/latexindent/LatexIndent/Wrap.pm @@ -63,7 +63,7 @@ sub text_wrap { /sx; } elsif ( $blocksFollowEachPart eq "commentOnPreviousLine" ) { - $blocksFollowEachPart = qr/^$trailingCommentRegExp/m; + $blocksFollowEachPart = qr/(?:^\h*$trailingCommentRegExp\R?)+/m; } elsif ( $blocksFollowEachPart eq "verbatim" ) { $blocksFollowEachPart = qr/$tokens{verbatim}\d+$tokens{endOfToken}/; @@ -103,7 +103,7 @@ sub text_wrap { elsif ( $blocksFollowEachPart eq "other" ) { $blocksFollowEachPart = qr/$yesNo/x; } - $blocksFollow .= ( $blocksFollow eq '' ? q() : "|" ) . qr/$blocksFollowEachPart/sx; + $blocksFollow .= ( $blocksFollow eq '' ? q() : "|" ) . qr/$blocksFollowEachPart/s; } } @@ -118,7 +118,13 @@ sub text_wrap { } # followed by 0 or more h-space and line breaks - $blocksFollow = ( $blocksFollow eq '' ? q() : qr/(?:$blocksFollow)(?:\h|\R)*/sx ); + if ( ${ ${ $mainSettings{modifyLineBreaks}{textWrapOptions} }{blocksFollow} }{commentOnPreviousLine} ) { + $blocksFollow + = ( $blocksFollow eq '' ? q() : qr/(?:$blocksFollow)(?:\h|\R)*(?:$trailingCommentRegExp\R\h*)?/s ); + } + else { + $blocksFollow = ( $blocksFollow eq '' ? q() : qr/(?:$blocksFollow)(?:\h|\R)*/s ); + } $logger->trace("textWrap blocks follow regexp:") if ( $is_tt_switch_active and ${$self}{modifyLineBreaksYamlName} ne 'sentence' ); @@ -181,7 +187,7 @@ sub text_wrap { $logger->trace( "textWrap Blocks ENDS with commentOnOwnLine (see textWrap:blocksEndBefore:commentOnOwnLine)") if $is_t_switch_active; - $blocksEndBeforeEachPart = qr/^$trailingCommentRegExp/m; + $blocksEndBeforeEachPart = qr/^\h*$trailingCommentRegExp/m; } elsif ( $blocksEndBeforeEachPart eq "verbatim" ) { $logger->trace("textWrap Blocks ENDS with verbatim (see textWrap:blocksEndBefore:verbatim)") @@ -326,6 +332,8 @@ sub text_wrap { else { my $thingToMeasure = ( split( /\R/, $textWrapBlockStorage[ $textWrapBlockCount - 1 ] ) )[-1]; $thingToMeasure =~ s/$tokens{blanklines}//; + $thingToMeasure =~ s/$tokens{verbatim}//; + $thingToMeasure =~ s/$trailingCommentRegExp//; $subsequentSpace = ( $textWrapBlockCount == 0 diff --git a/Master/texmf-dist/scripts/latexindent/defaultSettings.yaml b/Master/texmf-dist/scripts/latexindent/defaultSettings.yaml index 9d16992e360..e626458b63f 100755 --- a/Master/texmf-dist/scripts/latexindent/defaultSettings.yaml +++ b/Master/texmf-dist/scripts/latexindent/defaultSettings.yaml @@ -1,5 +1,5 @@ # -# latexindent.pl, version 3.22, 2023-06-01 +# latexindent.pl, version 3.22.1, 2023-07-02 # # defaultSettings.yaml, the default settings for latexindent.pl # diff --git a/Master/texmf-dist/scripts/latexindent/latexindent.pl b/Master/texmf-dist/scripts/latexindent/latexindent.pl index 5dacf0bc84d..a4cf71ab954 100755 --- a/Master/texmf-dist/scripts/latexindent/latexindent.pl +++ b/Master/texmf-dist/scripts/latexindent/latexindent.pl @@ -1,6 +1,6 @@ #!/usr/bin/env perl # -# latexindent.pl, version 3.22, 2023-06-01 +# latexindent.pl, version 3.22.1, 2023-07-02 # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by |