summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/scripts/l3build
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/scripts/l3build')
-rw-r--r--Master/texmf-dist/scripts/l3build/l3build-arguments.lua17
-rw-r--r--Master/texmf-dist/scripts/l3build/l3build-check.lua35
-rw-r--r--Master/texmf-dist/scripts/l3build/l3build-upload.lua5
-rwxr-xr-xMaster/texmf-dist/scripts/l3build/l3build.lua2
4 files changed, 42 insertions, 17 deletions
diff --git a/Master/texmf-dist/scripts/l3build/l3build-arguments.lua b/Master/texmf-dist/scripts/l3build/l3build-arguments.lua
index a6a13a43fee..cbf68c6254a 100644
--- a/Master/texmf-dist/scripts/l3build/l3build-arguments.lua
+++ b/Master/texmf-dist/scripts/l3build/l3build-arguments.lua
@@ -111,12 +111,6 @@ option_list =
short = "h",
type = "boolean"
},
- quiet =
- {
- desc = "Suppresses TeX output when unpacking",
- short = "q",
- type = "boolean"
- },
last =
{
desc = "Name of last test to run",
@@ -128,11 +122,22 @@ option_list =
short = "m",
type = "string"
},
+ quiet =
+ {
+ desc = "Suppresses TeX output when unpacking",
+ short = "q",
+ type = "boolean"
+ },
rerun =
{
desc = "Skip setup: simply rerun tests",
type = "boolean"
},
+ ["show-log-on-error"] =
+ {
+ desc = "If 'halt-on-error' stops, show the full log of the failure",
+ type = "boolean"
+ },
shuffle =
{
desc = "Shuffle order of tests",
diff --git a/Master/texmf-dist/scripts/l3build/l3build-check.lua b/Master/texmf-dist/scripts/l3build/l3build-check.lua
index 96c5d719949..301c0df1853 100644
--- a/Master/texmf-dist/scripts/l3build/l3build-check.lua
+++ b/Master/texmf-dist/scripts/l3build/l3build-check.lua
@@ -243,6 +243,9 @@ local function normalize_log(content,engine,errlevels)
match(line, "^used structure >") then
return ""
end
+ -- The first time a new font is used by LuaTeX, it shows up
+ -- as being cached: make it appear loaded every time
+ line = gsub(line, "save cache:", "load cache:")
-- A tidy-up to keep LuaTeX and other engines in sync
line = gsub(line, utf8_char(127), "^^?")
-- Unicode engines display chars in the upper half of the 8-bit range:
@@ -345,9 +348,6 @@ local function normalize_lua_log(content,luatex)
"Missing character: There is no (%^%^..) %(U%+(....)%)",
"Missing character: There is no %1"
)
- -- The first time a new font is used, it shows up
- -- as being cached
- line = gsub(line, "(save cache:", "(load cache:")
-- LuaTeX from v1.07 logs kerns differently ...
-- This block only applies to the output of LuaTeX itself,
-- hence needing a flag to skip the case of the reference log
@@ -544,9 +544,14 @@ function runcheck(name, hide)
local function check_and_diff(ext,engine,comp,pdftest)
runtest(name,engine,hide,ext,pdftest,true)
local errorlevel = comp(name,engine)
- if errorlevel ~= 0 and options["halt-on-error"] then
+ if errorlevel == 0 then
+ return errorlevel
+ end
+ if options["show-log-on-error"] then
+ showfailedlog(name)
+ end
+ if options["halt-on-error"] then
showfaileddiff()
- return 1
end
return errorlevel
end
@@ -728,7 +733,7 @@ function runtest(name, engine, hide, ext, pdfmode, breakout)
-- Ensure lines are of a known length
os_setenv .. " max_print_line=" .. maxprintline
.. os_concat ..
- binary .. format
+ binary .. format
.. " " .. asciiopt .. " " .. checkopts
.. setup(lvtfile)
.. (hide and (" > " .. os_null) or "")
@@ -907,6 +912,20 @@ function checkdiff()
print("")
end
+function showfailedlog(name)
+ print("\nCheck failed with log file")
+ for _,i in ipairs(filelist(testdir, name..".log")) do
+ print(" - " .. testdir .. "/" .. i)
+ print("")
+ local f = open(testdir .. "/" .. i,"r")
+ local content = f:read("*all")
+ close(f)
+ print("-----------------------------------------------------------------------------------")
+ print(content)
+ print("-----------------------------------------------------------------------------------")
+ end
+end
+
function showfaileddiff()
print("\nCheck failed with difference file")
for _,i in ipairs(filelist(testdir, "*" .. os_diffext)) do
@@ -927,7 +946,7 @@ function save(names)
for _,name in pairs(names) do
if testexists(name) then
for _,engine in pairs(engines) do
- local testengine = ((engine == stdengine and "") or "." .. engine)
+ local testengine = ((engine == stdengine and "") or "." .. engine)
local function save_test(test_ext,gen_ext,out_ext,pdfmode)
local out_file = name .. testengine .. out_ext
local gen_file = name .. "." .. engine .. gen_ext
@@ -956,7 +975,7 @@ function save(names)
return 1
else
print('Test "'.. name .. '"not found')
- return 1
+ return 1
end
end
return 0
diff --git a/Master/texmf-dist/scripts/l3build/l3build-upload.lua b/Master/texmf-dist/scripts/l3build/l3build-upload.lua
index 4256ed0854f..de1899ad2cb 100644
--- a/Master/texmf-dist/scripts/l3build/l3build-upload.lua
+++ b/Master/texmf-dist/scripts/l3build/l3build-upload.lua
@@ -121,12 +121,13 @@ function upload(tagnames)
-- curl file version
- local curlopt=open(ctanzip .. ".curlopt","w")
+ local curloptfile = uploadconfig.curlopt_file or (ctanzip .. ".curlopt")
+ local curlopt=open(curloptfile,"w")
output(curlopt)
write(ctan_post)
close(curlopt)
- ctan_post=curlexe .. " --config " .. ctanzip .. ".curlopt"
+ ctan_post=curlexe .. " --config " .. curloptfile
if options["debug"] then
diff --git a/Master/texmf-dist/scripts/l3build/l3build.lua b/Master/texmf-dist/scripts/l3build/l3build.lua
index 4c8cd86c075..9d51648553a 100755
--- a/Master/texmf-dist/scripts/l3build/l3build.lua
+++ b/Master/texmf-dist/scripts/l3build/l3build.lua
@@ -25,7 +25,7 @@ for those people who are interested.
--]]
-- Version information
-release_date = "2019-02-10"
+release_date = "2019-06-18"
-- File operations are aided by the LuaFileSystem module
local lfs = require("lfs")