From 3a59b8b6b226ed22ccd16aec2dc2e272f015cc74 Mon Sep 17 00:00:00 2001 From: Elie Roux Date: Fri, 19 Apr 2013 18:38:10 +0200 Subject: Less verbose output - first step Is it possible to adapt something like this in the ConTeXt files? --- otfl-fonts.lua | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'otfl-fonts.lua') diff --git a/otfl-fonts.lua b/otfl-fonts.lua index 75bd079..7e32465 100644 --- a/otfl-fonts.lua +++ b/otfl-fonts.lua @@ -37,10 +37,12 @@ if not generic_context then generic_context = { } end +local printinfo = function(s) texio.write_nl("log", s) end + if not generic_context.push_namespaces then function generic_context.push_namespaces() - texio.write(" ") + printinfo(" ") local normalglobal = { } for k, v in next, _G do normalglobal[k] = v @@ -50,7 +52,7 @@ if not generic_context.push_namespaces then function generic_context.pop_namespaces(normalglobal,isolate) if normalglobal then - texio.write(" ") + printinfo(" ") for k, v in next, _G do if not normalglobal[k] then generic_context[k] = v @@ -110,7 +112,7 @@ local function loadmodule(name,continue) end else if verbose then - texio.write(string.format(" <%s>",foundname)) -- no file.basename yet + printinfo(string.format(" <%s>",foundname)) -- no file.basename yet end dofile(foundname) end @@ -252,6 +254,6 @@ end -- We're done. -texio.write(string.format(" ", os.gettimeofday()-starttime)) +--texio.write(string.format(" ", os.gettimeofday()-starttime)) generic_context.pop_namespaces(whatever) -- cgit v1.2.3