summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/context/base/core-ctx.lua
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/context/base/core-ctx.lua')
-rw-r--r--Master/texmf-dist/tex/context/base/core-ctx.lua17
1 files changed, 10 insertions, 7 deletions
diff --git a/Master/texmf-dist/tex/context/base/core-ctx.lua b/Master/texmf-dist/tex/context/base/core-ctx.lua
index 1dad7c2d73a..e6fb7bb5fd8 100644
--- a/Master/texmf-dist/tex/context/base/core-ctx.lua
+++ b/Master/texmf-dist/tex/context/base/core-ctx.lua
@@ -6,9 +6,12 @@ if not modules then modules = { } end modules ['core-ctx'] = {
license = "see context related readme files"
}
-local trace_prepfiles = false trackers.register("resolvers.prepfiles", function(v) trace_prepfiles = v end)
+local trace_prepfiles = false trackers.register("system.prepfiles", function(v) trace_prepfiles = v end)
-commands = commands or { }
+local report_prepfiles = logs.reporter("system","prepfiles")
+
+commands = commands or { }
+local commands = commands
local list, suffix, islocal, found = { }, "prep", false, false
@@ -20,9 +23,9 @@ function commands.loadctxpreplist()
islocal = xml.found(x,"ctx:preplist[@local=='yes']")
--~ if trace_prepfiles then
if islocal then
- commands.writestatus("systems","loading ctx log file (local)") -- todo: m!systems
+ report_prepfiles("loading ctx log file (local)") -- todo: m!system
else
- commands.writestatus("systems","loading ctx log file (specified)") -- todo: m!systems
+ report_prepfiles("loading ctx log file (specified)") -- todo: m!system
end
--~ end
for e in xml.collected(x,"ctx:prepfile") do
@@ -32,7 +35,7 @@ function commands.loadctxpreplist()
end
local done = e.at['done'] or 'no'
if trace_prepfiles then
- commands.writestatus("systems","registering %s -> %s",done)
+ report_prepfiles("registering %s -> %s",done)
end
found = true
list[name] = done -- 'yes' or 'no'
@@ -47,7 +50,7 @@ local function found(name) -- used in resolve
local prepname = name .. "." .. suffix
if list[name] and lfs.isfile(prepname) then
if trace_prepfiles then
- commands.writestatus("systems", "preprocessing: using %s",prepname)
+ report_prepfiles("preprocessing: using %s",prepname)
end
return prepname
end
@@ -55,7 +58,7 @@ local function found(name) -- used in resolve
end
local function resolve(name) -- used a few times later on
- local filename = file.collapse_path(name)
+ local filename = file.collapsepath(name)
local prepname = islocal and found(file.basename(name))
if prepname then
return prepname