[latex3-commits] [git/LaTeX3-latex3-l3build] main: Unify `testdir`, always without trailing `.lua` (76d56e3)
Joseph Wright
joseph.wright at morningstar2.co.uk
Sun Feb 19 19:44:46 CET 2023
Repository : https://github.com/latex3/l3build
On branch : main
Link : https://github.com/latex3/l3build/commit/76d56e3818ec48dc108a2496af412e689508ebaf
>---------------------------------------------------------------
commit 76d56e3818ec48dc108a2496af412e689508ebaf
Author: Yukai Chou <muzimuzhi at gmail.com>
Date: Sun Feb 19 17:35:36 2023 +0800
Unify `testdir`, always without trailing `.lua`
>---------------------------------------------------------------
76d56e3818ec48dc108a2496af412e689508ebaf
CHANGELOG.md | 3 +++
l3build.lua | 5 +++--
2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index b9769db..92da5e8 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -7,6 +7,9 @@ this project uses date-based 'snapshot' version identifiers.
## [Unreleased]
+### Changed
+- Unify `testdir` by dropping possibly trailing `.lua` passed to `--config`
+
### Fixed
- Ensure directories `testdir` and `resultdir` exist when `--dirty` is set
- epoch settings with xetex
diff --git a/l3build.lua b/l3build.lua
index 110d394..afd309f 100644
--- a/l3build.lua
+++ b/l3build.lua
@@ -207,11 +207,12 @@ end
if #checkconfigs == 1 and
checkconfigs[1] ~= "build" and
(options["target"] == "check" or options["target"] == "save" or options["target"] == "clean") then
- local config = "./" .. gsub(checkconfigs[1],"%.lua$","") .. ".lua"
+ local configname = gsub(checkconfigs[1], "%.lua$", "")
+ local config = "./" .. configname .. ".lua"
if fileexists(config) then
local savedtestfiledir = testfiledir
dofile(config)
- testdir = testdir .. "-" .. checkconfigs[1]
+ testdir = testdir .. "-" .. configname
-- Reset testsuppdir if required
if savedtestfiledir ~= testfiledir and
testsuppdir == savedtestfiledir .. "/support" then
More information about the latex3-commits
mailing list.