Skip to content

Commit

Permalink
Merge pull request #536 from Witiko/feat/explcheck
Browse files Browse the repository at this point in the history
Use explcheck to check expl3 code in the continuous integration
  • Loading branch information
Witiko authored Dec 12, 2024
2 parents 687c762 + 3f0a535 commit 4fed6cb
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 7 deletions.
49 changes: 46 additions & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,17 @@ jobs:
with:
repository: ${{ github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name || github.repository }}
ref: ${{ github.event_name == 'pull_request_target' && github.event.pull_request.head.sha || github.sha }}
- name: Install TeX Live
uses: teatimeguest/setup-texlive-action@v3
with:
packages: |
scheme-minimal
xetex
- name: Install additional packages
run: |
set -ex
sudo apt -qy update
sudo apt -qy install --no-install-recommends git latexmk lua-check make texlive-xetex
sudo apt -qy install --no-install-recommends git latexmk lua-check make
- name: Extract scripts
run: make base
- name: Check the line length
Expand All @@ -74,15 +80,45 @@ jobs:
with:
repository: ${{ github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name || github.repository }}
ref: ${{ github.event_name == 'pull_request_target' && github.event.pull_request.head.sha || github.sha }}
- name: Install TeX Live
uses: teatimeguest/setup-texlive-action@v3
with:
packages: |
scheme-minimal
xetex
- name: Install additional packages
run: |
set -ex
sudo apt -qy update
sudo apt -qy install --no-install-recommends git latexmk lua-check make texlive-xetex
sudo apt -qy install --no-install-recommends git latexmk lua-check make
- name: Extract Lua scripts
run: make base
- name: Run luacheck
run: luacheck *.lua
explcheck:
name: Style check (expl3)
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
repository: ${{ github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name || github.repository }}
ref: ${{ github.event_name == 'pull_request_target' && github.event.pull_request.head.sha || github.sha }}
- name: Install TeX Live
uses: teatimeguest/setup-texlive-action@v3
with:
packages: |
scheme-minimal
xetex
- name: Install additional packages
run: |
set -ex
sudo apt -qy update
sudo apt -qy install --no-install-recommends git latexmk make
- name: Extract TeX files
run: make base
- name: Run explcheck
run: explcheck --warnings-are-errors -- *.tex *.sty
markdownlint:
name: Style check (Markdown)
runs-on: ubuntu-latest
Expand All @@ -92,11 +128,17 @@ jobs:
with:
repository: ${{ github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name || github.repository }}
ref: ${{ github.event_name == 'pull_request_target' && github.event.pull_request.head.sha || github.sha }}
- name: Install TeX Live
uses: teatimeguest/setup-texlive-action@v3
with:
packages: |
scheme-minimal
xetex
- name: Install additional packages
run: |
set -ex
sudo apt -qy update
sudo apt -qy install --no-install-recommends git latexmk lua-check make texlive-xetex
sudo apt -qy install --no-install-recommends git latexmk make
- name: Extract user manual
run: make markdown-transcluded.md
- name: Run MarkdownLint
Expand Down Expand Up @@ -150,6 +192,7 @@ jobs:
- linelength
- shellcheck
- luacheck
- explcheck
- markdownlint
- pytype
strategy:
Expand Down
4 changes: 4 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

## 3.9.1

Continuous Integration:

- Use explcheck to check expl3 code in the continuous integration. (#535, #536)

Distribution:

- Make `markdown-cli` executable and symlink it to system directories.
Expand Down
5 changes: 1 addition & 4 deletions markdown.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -1245,7 +1245,7 @@ hard l3kernel
%<*context,tex>
% \fi
% \begin{macrocode}
\ifx\ExplSyntaxOn\undefined
\expandafter\ifx\csname ExplSyntaxOn\endcsname\relax
\input expl3-generic
\fi
% \end{macrocode}
Expand Down Expand Up @@ -13588,7 +13588,6 @@ In this section, I will describe the individual token renderers.
%
% \end{markdown}
% \begin{macrocode}
\ExplSyntaxOn
\seq_new:N \g_@@_renderers_seq
% \end{macrocode}
% \begin{markdown}
Expand Down Expand Up @@ -19892,7 +19891,6 @@ following text:
% \fi
%
% \begin{macrocode}
\ExplSyntaxOn
\cs_gset_protected:Npn
\markdownRendererSuperscript
{
Expand Down Expand Up @@ -38741,7 +38739,6 @@ end
%
% \end{markdown}
% \begin{macrocode}
\ExplSyntaxOn
\seq_new:N
\l_@@_image_identifiers_seq
\markdownSetup {
Expand Down

0 comments on commit 4fed6cb

Please sign in to comment.