summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/l3build
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2017-04-09 22:51:05 +0000
committerKarl Berry <karl@freefriends.org>2017-04-09 22:51:05 +0000
commitfb68869e1920f0aabf41343b670279f0be3bb054 (patch)
tree175d01a8cfb871160d931f41c90fb24fb74d643a /Master/texmf-dist/tex/latex/l3build
parent4978fc50e9868db202f4b51324b37a4f2e201f1e (diff)
l3
git-svn-id: svn://tug.org/texlive/trunk@43727 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/l3build')
-rw-r--r--Master/texmf-dist/tex/latex/l3build/l3build.lua25
1 files changed, 18 insertions, 7 deletions
diff --git a/Master/texmf-dist/tex/latex/l3build/l3build.lua b/Master/texmf-dist/tex/latex/l3build/l3build.lua
index 7d218d08274..b3d55b0fb00 100644
--- a/Master/texmf-dist/tex/latex/l3build/l3build.lua
+++ b/Master/texmf-dist/tex/latex/l3build/l3build.lua
@@ -23,8 +23,7 @@ for those people who are interested.
--]]
-- Version information: should be identical to that in l3build.dtx
-release_date = "2017/03/18"
-release_ver = "7019"
+release_date = "2017/04/01"
-- "module" is a deprecated function in Lua 5.2: as we want the name
-- for other purposes, and it should eventually be 'free', simply
@@ -410,7 +409,12 @@ if os.type == "windows" then
os_diffext = os.getenv("diffext") or ".fc"
os_diffexe = os.getenv("diffexe") or "fc /n"
os_grepexe = "findstr /r"
- os_newline = "\r\n"
+ os_newline = "\n"
+ if tonumber(status.luatex_version) < 100 or
+ (tonumber(status.luatex_version) == 100
+ and tonumber(status.luatex_revision) < 4) then
+ os_newline = "\r\n"
+ end
os_null = "nul"
os_pathsep = ";"
os_setenv = "set"
@@ -867,7 +871,11 @@ function formatlog(logfile, newfile, engine)
local newlog = ""
local prestart = true
local skipping = false
- for line in io.lines(logfile) do
+ -- Read the entire log file as a binary: deals with ^@/^[, etc.
+ local file = assert(io.open(logfile, "rb"))
+ local contents = string.gsub(file:read("*all") .. "\n", "\r\n", "\n")
+ io.close(file)
+ for line in string.gmatch(contents, "([^\n]*)\n") do
if line == "START-TEST-LOG" then
prestart = false
elseif line == "END-TEST-LOG" then
@@ -1060,7 +1068,11 @@ function formatlualog(logfile, newfile)
local newlog = ""
local lastline = ""
local dropping = false
- for line in io.lines(logfile) do
+ -- Read the entire log file as a binary: deals with ^@/^[, etc.
+ local file = assert(io.open(logfile, "rb"))
+ local contents = string.gsub(file:read("*all") .. "\n", "\r\n", "\n")
+ io.close(file)
+ for line in string.gmatch(contents, "([^\n]*)\n") do
line, lastline, dropping = normalize(line, lastline, dropping)
if not string.match(line, "^ *$") then
newlog = newlog .. line .. os_newline
@@ -2095,8 +2107,7 @@ end
function version()
print(
"\n"
- .. "l3build Release " .. string.gsub(release_date, "/", "-")
- .. " (SVN r" .. release_ver .. ")\n"
+ .. "l3build Release " .. string.gsub(release_date, "/", "-") .. "\n"
)
end