Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
cmhughes committed Jul 18, 2024
2 parents fed474e + 3827ce7 commit 78d452f
Show file tree
Hide file tree
Showing 20 changed files with 45 additions and 22 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ FROM perl:5.40.0-slim-threaded-buster
#

ARG LATEXINDENT_VERSION
ENV LATEXINDENT_VERSION ${LATEXINDENT_VERSION:-V3.24.3}
ENV LATEXINDENT_VERSION ${LATEXINDENT_VERSION:-V3.24.4}

RUN apt-get update \
&& apt-get install \
Expand Down
4 changes: 2 additions & 2 deletions LatexIndent/Version.pm
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@ use warnings;
use Exporter qw/import/;
our @EXPORT_OK = qw/$versionNumber $versionDate/;

our $versionNumber = '3.24.3';
our $versionDate = '2024-07-14';
our $versionNumber = '3.24.4';
our $versionDate = '2024-07-18';
1
7 changes: 7 additions & 0 deletions LatexIndent/Wrap.pm
Original file line number Diff line number Diff line change
Expand Up @@ -659,6 +659,13 @@ sub text_wrap_comment_blocks {
# call the text wrapping routine
my $columns = ${ $mainSettings{modifyLineBreaks}{textWrapOptions} }{columns};

# fail gracefully if columns == 0
if ($columns==0){
$logger->warn("* textWrapOptions: columns is set to 0, can't text wrap with this");
${ ${ $mainSettings{modifyLineBreaks}{textWrapOptions} }{comments} }{wrap} = 0;
return;
}

#
# text wrap comment blocks
#
Expand Down
2 changes: 1 addition & 1 deletion defaultSettings.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# latexindent.pl, version 3.24.3, 2024-07-14
# latexindent.pl, version 3.24.4, 2024-07-18
#
# defaultSettings.yaml, the default settings for latexindent.pl
#
Expand Down
5 changes: 4 additions & 1 deletion documentation/changelog.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
<!-- announcement: -y switch bug fix for lookForAlignDelims-->
<!-- announcement: graceful fail for columns=0 text wrapping-->

# changelog.md
## V3.24.4, July 18, 2024
graceful fail for `columns=0` when text wrapping block comments, see [issue 552](https://github.com/cmhughes/latexindent.pl/issues/552)

## V3.24.3, July 14, 2024
`-y` switch bug fix for `lookForAlignDelims`, see [issue 551](https://github.com/cmhughes/latexindent.pl/issues/551)

Expand Down
4 changes: 2 additions & 2 deletions documentation/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,9 @@
# built documents.
#
# The short X.Y version.
version = u'3.24.3'
version = u'3.24.4'
# The full version, including alpha/beta/rc tags.
release = u'3.24.3'
release = u'3.24.4'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
2 changes: 1 addition & 1 deletion documentation/demonstrations/pre-commit-config-conda.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
- repo: https://github.com/cmhughes/latexindent.pl
rev: V3.24.3
rev: V3.24.4
hooks:
- id: latexindent-conda
args: [-s]
2 changes: 1 addition & 1 deletion documentation/demonstrations/pre-commit-config-cpan.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
- repo: https://github.com/cmhughes/latexindent.pl
rev: V3.24.3
rev: V3.24.4
hooks:
- id: latexindent
args: [-s]
2 changes: 1 addition & 1 deletion documentation/demonstrations/pre-commit-config-demo.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
- repo: https://github.com/cmhughes/latexindent.pl
rev: V3.24.3
rev: V3.24.4
hooks:
- id: latexindent
args: [-l, -m, -s, -w]
2 changes: 1 addition & 1 deletion documentation/demonstrations/pre-commit-config-docker.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
- repo: https://github.com/cmhughes/latexindent.pl
rev: V3.24.3
rev: V3.24.4
hooks:
- id: latexindent-docker
args: [-s]
2 changes: 1 addition & 1 deletion documentation/latexindent-yaml-schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -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.24.3 2024-07-14",
"description": "latexindent.pl YAML schema helper, V3.24.4 2024-07-18",
"type": "object",
"properties": {
"fileExtensionPreference": {
Expand Down
2 changes: 1 addition & 1 deletion documentation/readme.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
latexindent.pl, version 3.24.3, 2024-07-14
latexindent.pl, version 3.24.4, 2024-07-18

PERL script to indent code within environments, and align delimited
environments in .tex files.
Expand Down
4 changes: 2 additions & 2 deletions documentation/title.tex
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@
sharp corners,
enhanced,
overlay={\node[anchor=north east,outer sep=2pt] at ([xshift=3cm,yshift=4mm]frame.north east) {\includegraphics[width=3cm]{logo}}; }]
\centering\ttfamily\bfseries latexindent.pl\\[1cm] Version 3.24.3
\centering\ttfamily\bfseries latexindent.pl\\[1cm] Version 3.24.4
\end{tcolorbox}
}
\author{Chris Hughes \thanks{and contributors!
See \vref{sec:contributors}.
For
all communication, please visit \cite{latexindent-home}.}}
\date{2024-07-14}
\date{2024-07-18}
\maketitle
\begin{adjustwidth}{1cm}{1cm}
\small
Expand Down
8 changes: 4 additions & 4 deletions helper-scripts/update-version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,10 @@
# - <upload latexindent.zip to ctan>

minorVersion=0
oldVersion='3.24.2'
newVersion='3.24.3'
oldDate='2024-06-15'
newDate='2024-07-14'
oldVersion='3.24.3'
newVersion='3.24.4'
oldDate='2024-07-14'
newDate='2024-07-18'
updateVersion=0
gitMode=0

Expand Down
2 changes: 1 addition & 1 deletion latexindent.pl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env perl
#
# latexindent.pl, version 3.24.3, 2024-07-14
# latexindent.pl, version 3.24.4, 2024-07-18
#
# 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
Expand Down
4 changes: 2 additions & 2 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ and [pre-commit](https://latexindentpl.readthedocs.io/en/latest/sec-appendices.h

## version

latexindent.pl, version 3.24.3, 2024-07-14
latexindent.pl, version 3.24.4, 2024-07-18

## author
Chris Hughes (cmhughes)
Expand Down Expand Up @@ -157,7 +157,7 @@ framework](https://pre-commit.com) by adding this to your

```yaml
- repo: https://github.com/cmhughes/latexindent.pl.git
rev: V3.24.3
rev: V3.24.4
hooks:
- id: latexindent
```
Expand Down
2 changes: 2 additions & 0 deletions test-cases/text-wrap/issue-552.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
% 1
% 2
2 changes: 2 additions & 0 deletions test-cases/text-wrap/issue-552.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
WARN: textWrapOptions: columns is set to 0, can't text wrap with this
No objects found.
4 changes: 4 additions & 0 deletions test-cases/text-wrap/issue-552.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
modifyLineBreaks:
textWrapOptions:
comments:
wrap: 1
5 changes: 5 additions & 0 deletions test-cases/text-wrap/text-wrap-remove-PLB.sh
Original file line number Diff line number Diff line change
Expand Up @@ -281,6 +281,11 @@ latexindent.pl -s -m -r -l issue-502.yaml,addruler2.yaml issue-502.tex -o=+-mod1
latexindent.pl -s -m -r -l issue-502a.yaml,addruler2.yaml issue-502a.tex -o=+-mod1

latexindent.pl -s -l issue-506.yaml -m issue-506.tex -o=+-mod1

latexindent.pl -l issue-552.yaml -m issue-552.tex -s
cp indent.log issue-552.txt
perl -p0i -e 's/.*?(WARN)/$1/s' issue-552.txt
perl -p0i -e 's/INFO:.*//s' issue-552.txt
set +x
[[ $gitStatus == 1 ]] && git status
[[ $noisyMode == 1 ]] && makenoise
Expand Down

0 comments on commit 78d452f

Please sign in to comment.