From 3e552e98a5d32ac0048dcc7e04daa491d723e105 Mon Sep 17 00:00:00 2001 From: Hans Hagen Date: Fri, 22 Mar 2013 20:06:00 +0100 Subject: beta 2013.03.22 20:06 --- tex/context/base/context-version.pdf | Bin 4140 -> 4131 bytes tex/context/base/context-version.png | Bin 40493 -> 40141 bytes tex/context/base/status-files.pdf | Bin 24806 -> 24813 bytes tex/context/base/status-lua.pdf | Bin 211576 -> 211541 bytes tex/context/base/trac-exp.lua | 23 ++++---- tex/context/base/trac-log.lua | 106 +++++++++++++++++------------------ 6 files changed, 64 insertions(+), 65 deletions(-) (limited to 'tex') diff --git a/tex/context/base/context-version.pdf b/tex/context/base/context-version.pdf index 3ae8d02e8..bdec51852 100644 Binary files a/tex/context/base/context-version.pdf and b/tex/context/base/context-version.pdf differ diff --git a/tex/context/base/context-version.png b/tex/context/base/context-version.png index f6082b439..a574743b8 100644 Binary files a/tex/context/base/context-version.png and b/tex/context/base/context-version.png differ diff --git a/tex/context/base/status-files.pdf b/tex/context/base/status-files.pdf index f75ab6cd1..31f682298 100644 Binary files a/tex/context/base/status-files.pdf and b/tex/context/base/status-files.pdf differ diff --git a/tex/context/base/status-lua.pdf b/tex/context/base/status-lua.pdf index f6fc14091..557386802 100644 Binary files a/tex/context/base/status-lua.pdf and b/tex/context/base/status-lua.pdf differ diff --git a/tex/context/base/trac-exp.lua b/tex/context/base/trac-exp.lua index b9b4143d3..5879f1b7b 100644 --- a/tex/context/base/trac-exp.lua +++ b/tex/context/base/trac-exp.lua @@ -63,21 +63,16 @@ function exporters.man(specification,...) runner = name end -- - result[#result+1] = formatters[ [[.TH "%s" "1" "%s" "version %s" "%s" ]] ](name,os.date("01-01-%Y"),version,detail) - result[#result+1] = ".PP" - result[#result+1] = formatters[ [[.SH "NAME" %s]] ] () - result[#result+1] = ".PP" - result[#result+1] = formatters[ [[.SH "SYNOPSIS" ]] ](name) - result[#result+1] = ".PP" - result[#result+1] = formatters[ [[.SH \fB%s\fP [ \fIOPTIONS\fP ... ] [ \fIFILENAMES\fP ] ]] ](runner) - result[#result+1] = ".PP" - result[#result+1] = formatters[ [[.SH "DESCRIPTION"\n%s\n ]] ](detail) + result[#result+1] = formatters['.TH "%s" "1" "%s" "version %s" "%s"'](name,os.date("01-01-%Y"),version,detail) + result[#result+1] = formatters[".SH NAME\n.B %s"](name) + result[#result+1] = formatters[".SH SYNOPSIS\n.B %s [\n.I OPTIONS ...\n.B ] [\n.I FILENAMES\n.B ]"](runner) + result[#result+1] = formatters[".SH DESCRIPTION\n.B %s"](detail) -- for category in xmlcollected(root,"/application/flags/category") do if nofcategories > 1 then - result[#result+1] = formatters['.SH "OPTIONS: %s"'](string.upper(category.at.name or "all")) + result[#result+1] = formatters['.SH OPTIONS: %s'](string.upper(category.at.name or "all")) else - result[#result+1] = '.SH "OPTIONS"' + result[#result+1] = ".SH OPTIONS" end for subcategory in xmlcollected(category,"/subcategory") do for flag in xmlcollected(subcategory,"/flag") do @@ -90,7 +85,11 @@ function exporters.man(specification,...) end end end - result[#result+1] = formatters['.SH "AUTHOR"\n%s'](specification.moreinfo) + local moreinfo = specification.moreinfo + if moreinfo and moreinfo ~= "" then + moreinfo = string.gsub(moreinfo,"[\n\r]([%a]+)%s*:%s*",'\n\n.B "%1:"\n') + result[#result+1] = formatters[".SH AUTHOR\n%s"](moreinfo) + end return table.concat(result,"\n") end diff --git a/tex/context/base/trac-log.lua b/tex/context/base/trac-log.lua index 211734ef3..feecdcb3b 100644 --- a/tex/context/base/trac-log.lua +++ b/tex/context/base/trac-log.lua @@ -6,59 +6,59 @@ if not modules then modules = { } end modules ['trac-log'] = { license = "see context related readme files" } -if tex and (tex.jobname or tex.formatname) then - - -- quick hack, awaiting speedup in engine (8 -> 6.4 sec for --make with console2) - - local texio_write_nl = texio.write_nl - local texio_write = texio.write - local io_write = io.write - - local write_nl = function(target,...) - if not io_write then - io_write = io.write - end - if target == "term and log" then - texio_write_nl("log",...) - texio_write_nl("term","") - io_write(...) - elseif target == "log" then - texio_write_nl("log",...) - elseif target == "term" then - texio_write_nl("term","") - io_write(...) - else - texio_write_nl("log",...) - texio_write_nl("term","") - io_write(...) - end - end - - local write = function(target,...) - if not io_write then - io_write = io.write - end - if target == "term and log" then - texio_write("log",...) - io_write(...) - elseif target == "log" then - texio_write("log",...) - elseif target == "term" then - io_write(...) - else - texio_write("log",...) - io_write(...) - end - end - - texio.write = write - texio.write_nl = write_nl - -else - - -- texlua or just lua - -end +-- if tex and (tex.jobname or tex.formatname) then +-- +-- -- quick hack, awaiting speedup in engine (8 -> 6.4 sec for --make with console2) +-- +-- local texio_write_nl = texio.write_nl +-- local texio_write = texio.write +-- local io_write = io.write +-- +-- local write_nl = function(target,...) +-- if not io_write then +-- io_write = io.write +-- end +-- if target == "term and log" then +-- texio_write_nl("log",...) +-- texio_write_nl("term","") +-- io_write(...) +-- elseif target == "log" then +-- texio_write_nl("log",...) +-- elseif target == "term" then +-- texio_write_nl("term","") +-- io_write(...) +-- else +-- texio_write_nl("log",...) +-- texio_write_nl("term","") +-- io_write(...) +-- end +-- end +-- +-- local write = function(target,...) +-- if not io_write then +-- io_write = io.write +-- end +-- if target == "term and log" then +-- texio_write("log",...) +-- io_write(...) +-- elseif target == "log" then +-- texio_write("log",...) +-- elseif target == "term" then +-- io_write(...) +-- else +-- texio_write("log",...) +-- io_write(...) +-- end +-- end +-- +-- texio.write = write +-- texio.write_nl = write_nl +-- +-- else +-- +-- -- texlua or just lua +-- +-- end -- todo: less categories, more subcategories (e.g. nodes) -- todo: split into basics and ctx specific -- cgit v1.2.3