Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
cmhughes committed Nov 19, 2023
2 parents 189bbc7 + 7d699ca commit bef6a51
Show file tree
Hide file tree
Showing 45 changed files with 252 additions and 102 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/batch-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
with:
fetch-depth: 2
- name: Check for changed pm files, latexindent.pl, defaultSettings.yaml
uses: tj-actions/changed-files@v39
uses: tj-actions/changed-files@v40
id: changed-files
with:
files: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pull-request-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
comment:
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@v6
- uses: actions/github-script@v7
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
Expand Down
5 changes: 2 additions & 3 deletions .github/workflows/test-cases-on-pull.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,8 @@ jobs:
fetch-depth: 0
- name: Get changed files, latexindent.pl
id: changed-files
uses: tj-actions/changed-files@v39
uses: tj-actions/changed-files@v40
with:
use_fork_point: "true"
files: |
latexindent.pl
defaultSettings.yaml
Expand Down Expand Up @@ -92,7 +91,7 @@ jobs:
sed -i.bak "s/checkgitdiff//" test-cases.sh
./test-cases.sh -s
- name: Check for changed files in test-cases
uses: tj-actions/changed-files@v39
uses: tj-actions/changed-files@v40
id: changed-files
with:
files: |
Expand Down
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.38.0-slim-threaded-buster
#

ARG LATEXINDENT_VERSION
ENV LATEXINDENT_VERSION ${LATEXINDENT_VERSION:-V3.23.3}
ENV LATEXINDENT_VERSION ${LATEXINDENT_VERSION:-V3.23.4}

RUN apt-get update \
&& apt-get install \
Expand Down
5 changes: 4 additions & 1 deletion LatexIndent/FileContents.pm
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,10 @@ sub find_file_contents_environments_and_preamble {
my $needToStorePreamble = 0;

# try and find the preamble
if ( ${$self}{body} =~ m/$preambleRegExp/sx and ${ $mainSettings{lookForPreamble} }{ ${$self}{fileExtension} } ) {
my $lookForPreamble = ${ $mainSettings{lookForPreamble} }{ ${$self}{fileExtension} };
$lookForPreamble = 1 if ( ${$self}{fileName} eq "-" and ${ $mainSettings{lookForPreamble} }{STDIN} );

if ( ${$self}{body} =~ m/$preambleRegExp/sx and $lookForPreamble ) {

$logger->trace(
"\\begin{document} found in body (after searching for filecontents)-- assuming that a preamble exists")
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.23.3';
our $versionDate = '2023-10-13';
our $versionNumber = '3.23.4';
our $versionDate = '2023-11-19';
1
3 changes: 2 additions & 1 deletion defaultSettings.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# latexindent.pl, version 3.23.3, 2023-10-13
# latexindent.pl, version 3.23.4, 2023-11-19
#
# defaultSettings.yaml, the default settings for latexindent.pl
#
Expand Down Expand Up @@ -137,6 +137,7 @@ lookForPreamble:
.sty: 0
.cls: 0
.bib: 0
STDIN: 1

# some preambles can contain \begin and \end statements
# that are not in their 'standard environment block', for example,
Expand Down
4 changes: 3 additions & 1 deletion documentation/changelog.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
<!-- announcement: update to fineTuning, tweak to backup file routine-->
<!-- announcement: bugfix for STDIN when m switch active with preamble-->

# changelog.md
## V3.23.4, November 19, 2023
bugfix for STDIN input with preamble and m switch, see [issue-493](https://github.com/cmhughes/latexindent.pl/issues/493)

## V3.23.3, October 13, 2023
* update to `fineTuning`, see [issue-488](https://github.com/cmhughes/latexindent.pl/issues/488)
Expand Down
6 changes: 3 additions & 3 deletions documentation/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,16 +63,16 @@
# built documents.
#
# The short X.Y version.
version = u'3.23.3'
version = u'3.23.4'
# The full version, including alpha/beta/rc tags.
release = u'3.23.3'
release = u'3.23.4'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
#
# This is also used if you do content translation via gettext catalogs.
# Usually you set "language" from the command line for these cases.
language = None
language = 'en'

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
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.23.3
rev: V3.23.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.23.3
rev: V3.23.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.23.3
rev: V3.23.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.23.3
rev: V3.23.4
hooks:
- id: latexindent-docker
args: [-s]
2 changes: 1 addition & 1 deletion documentation/documentation-default-settings-update.pl
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
{name=>"noIndentBlock",numberOfLines=>2},
{name=>"removeTrailingWhitespace",numberOfLines=>2},
{name=>"fileContentsEnvironments",numberOfLines=>2},
{name=>"lookForPreamble",numberOfLines=>4},
{name=>"lookForPreamble",numberOfLines=>5},
{name=>"lookForAlignDelims",numberOfLines=>18},
{name=>"indentAfterItems",numberOfLines=>7},
{name=>"itemNames",numberOfLines=>2},
Expand Down
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.23.3 2023-10-13",
"description": "latexindent.pl YAML schema helper, V3.23.4 2023-11-19",
"type": "object",
"properties": {
"fileExtensionPreference": {
Expand Down
46 changes: 23 additions & 23 deletions documentation/latexindent.tex
Original file line number Diff line number Diff line change
Expand Up @@ -391,7 +391,7 @@

\lstdefinestyle{removeTrailingWhitespace}{
style=yaml-LST,
firstnumber=152,linerange={152-154},
firstnumber=153,linerange={153-155},
numbers=left,
}

Expand All @@ -403,133 +403,133 @@

\lstdefinestyle{lookForPreamble}{
style=yaml-LST,
firstnumber=135,linerange={135-139},
firstnumber=135,linerange={135-140},
numbers=left,
}

\lstdefinestyle{lookForAlignDelims}{
style=yaml-LST,
firstnumber=157,linerange={157-175},
firstnumber=158,linerange={158-176},
numbers=left,
}

\lstdefinestyle{indentAfterItems}{
style=yaml-LST,
firstnumber=240,linerange={240-247},
firstnumber=241,linerange={241-248},
numbers=left,
}

\lstdefinestyle{itemNames}{
style=yaml-LST,
firstnumber=253,linerange={253-255},
firstnumber=254,linerange={254-256},
numbers=left,
}

\lstdefinestyle{specialBeginEnd}{
style=yaml-LST,
firstnumber=259,linerange={259-273},
firstnumber=260,linerange={260-274},
numbers=left,
}

\lstdefinestyle{indentAfterHeadings}{
style=yaml-LST,
firstnumber=283,linerange={283-292},
firstnumber=284,linerange={284-293},
numbers=left,
}

\lstdefinestyle{noAdditionalIndentGlobalEnv}{
style=yaml-LST,
firstnumber=341,linerange={341-342},
firstnumber=342,linerange={342-343},
numbers=left,
}

\lstdefinestyle{noAdditionalIndentGlobal}{
style=yaml-LST,
firstnumber=341,linerange={341-353},
firstnumber=342,linerange={342-354},
numbers=left,
}

\lstdefinestyle{indentRulesGlobalEnv}{
style=yaml-LST,
firstnumber=357,linerange={357-358},
firstnumber=358,linerange={358-359},
numbers=left,
}

\lstdefinestyle{indentRulesGlobal}{
style=yaml-LST,
firstnumber=357,linerange={357-369},
firstnumber=358,linerange={358-370},
numbers=left,
}

\lstdefinestyle{commandCodeBlocks}{
style=yaml-LST,
firstnumber=372,linerange={372-387},
firstnumber=373,linerange={373-388},
numbers=left,
}

\lstdefinestyle{modifylinebreaks}{
style=yaml-LST,
firstnumber=500,linerange={500-502},
firstnumber=501,linerange={501-503},
numbers=left,
}

\lstdefinestyle{textWrapOptions}{
style=yaml-LST,
firstnumber=530,linerange={530-531},
firstnumber=531,linerange={531-532},
numbers=left,
}

\lstdefinestyle{textWrapOptionsAll}{
style=yaml-LST,
firstnumber=530,linerange={530-557},
firstnumber=531,linerange={531-558},
numbers=left,
}

\lstdefinestyle{oneSentencePerLine}{
style=yaml-LST,
firstnumber=503,linerange={503-529},
firstnumber=504,linerange={504-530},
numbers=left,
}

\lstdefinestyle{sentencesFollow}{
style=yaml-LST,
firstnumber=509,linerange={509-517},
firstnumber=510,linerange={510-518},
numbers=left,
}

\lstdefinestyle{sentencesBeginWith}{
style=yaml-LST,
firstnumber=518,linerange={518-521},
firstnumber=519,linerange={519-522},
numbers=left,
}

\lstdefinestyle{sentencesEndWith}{
style=yaml-LST,
firstnumber=522,linerange={522-527},
firstnumber=523,linerange={523-528},
numbers=left,
}

\lstdefinestyle{sentencesDoNOTcontain}{
style=yaml-LST,
firstnumber=528,linerange={528-529},
firstnumber=529,linerange={529-530},
numbers=left,
}

\lstdefinestyle{modifylinebreaksEnv}{
style=yaml-LST,
firstnumber=559,linerange={559-568},
firstnumber=560,linerange={560-569},
numbers=left,
}

\lstdefinestyle{replacements}{
style=yaml-LST,
firstnumber=620,linerange={620-625},
firstnumber=621,linerange={621-626},
numbers=left,
}

\lstdefinestyle{fineTuning}{
style=yaml-LST,
firstnumber=629,linerange={629-684},
firstnumber=630,linerange={630-685},
numbers=left,
}

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.23.3, 2023-10-13
latexindent.pl, version 3.23.4, 2023-11-19

PERL script to indent code within environments, and align delimited
environments in .tex files.
Expand Down
2 changes: 1 addition & 1 deletion documentation/sec-appendices.rst
Original file line number Diff line number Diff line change
Expand Up @@ -583,7 +583,7 @@ Once I have run the above, on subsequent logins I run
.. code-block:: latex
:caption: ``docker-install.sh``
:name: lst:docker-install
:name: lst:docker-install-subsequent
newgrp docker
docker run ghcr.io/cmhughes/latexindent.pl -h
Expand Down
2 changes: 1 addition & 1 deletion documentation/sec-appendices.tex
Original file line number Diff line number Diff line change
Expand Up @@ -493,7 +493,7 @@
\end{cmhlistings}

Once I have run the above, on subsequent logins I run
\begin{cmhlistings}[style=tcblatex,language=Bash]{\texttt{docker-install.sh}}{lst:docker-install}
\begin{cmhlistings}[style=tcblatex,language=Bash]{\texttt{docker-install.sh}}{lst:docker-install-subsequent}
newgrp docker
docker run ghcr.io/cmhughes/latexindent.pl -h
\end{cmhlistings}
Expand Down
Loading

0 comments on commit bef6a51

Please sign in to comment.