diff options
author | Context Git Mirror Bot <phg42.2a@gmail.com> | 2014-10-20 20:15:03 +0200 |
---|---|---|
committer | Context Git Mirror Bot <phg42.2a@gmail.com> | 2014-10-20 20:15:03 +0200 |
commit | 7cc87f17f5be2362f52c62c819e95042c5ae89f5 (patch) | |
tree | bfe6a1833b59d98f0b8cae8894c8dd87db22b885 /tex | |
parent | 6c19d03f787fca72445dc9582579e0ab9d58fdeb (diff) | |
download | context-7cc87f17f5be2362f52c62c819e95042c5ae89f5.tar.gz |
2014-10-20 19:33:00
Diffstat (limited to 'tex')
-rw-r--r-- | tex/context/base/cont-new.mkiv | 2 | ||||
-rw-r--r-- | tex/context/base/context-version.pdf | bin | 4387 -> 4383 bytes | |||
-rw-r--r-- | tex/context/base/context.mkiv | 2 | ||||
-rw-r--r-- | tex/context/base/publ-dat.lua | 34 | ||||
-rw-r--r-- | tex/context/base/status-files.pdf | bin | 24708 -> 24691 bytes | |||
-rw-r--r-- | tex/context/base/status-lua.pdf | bin | 333365 -> 333362 bytes | |||
-rw-r--r-- | tex/generic/context/luatex/luatex-fonts-merged.lua | 2 |
7 files changed, 22 insertions, 18 deletions
diff --git a/tex/context/base/cont-new.mkiv b/tex/context/base/cont-new.mkiv index daf0b11db..6a7a8e714 100644 --- a/tex/context/base/cont-new.mkiv +++ b/tex/context/base/cont-new.mkiv @@ -11,7 +11,7 @@ %C therefore copyrighted by \PRAGMA. See mreadme.pdf for %C details. -\newcontextversion{2014.10.20 19:02} +\newcontextversion{2014.10.20 19:31} %D This file is loaded at runtime, thereby providing an excellent place for %D hacks, patches, extensions and new features. diff --git a/tex/context/base/context-version.pdf b/tex/context/base/context-version.pdf Binary files differindex bce447fec..fc46759fd 100644 --- a/tex/context/base/context-version.pdf +++ b/tex/context/base/context-version.pdf diff --git a/tex/context/base/context.mkiv b/tex/context/base/context.mkiv index 324fe4ade..9e9ee8fd3 100644 --- a/tex/context/base/context.mkiv +++ b/tex/context/base/context.mkiv @@ -28,7 +28,7 @@ %D up and the dependencies are more consistent. \edef\contextformat {\jobname} -\edef\contextversion{2014.10.20 19:02} +\edef\contextversion{2014.10.20 19:31} \edef\contextkind {beta} %D For those who want to use this: diff --git a/tex/context/base/publ-dat.lua b/tex/context/base/publ-dat.lua index ac89918ee..424e7a00d 100644 --- a/tex/context/base/publ-dat.lua +++ b/tex/context/base/publ-dat.lua @@ -40,6 +40,8 @@ local setmetatableindex = table.setmetatableindex local P, R, S, V, C, Cc, Cs, Ct, Carg, Cmt = lpeg.P, lpeg.R, lpeg.S, lpeg.V, lpeg.C, lpeg.Cc, lpeg.Cs, lpeg.Ct, lpeg.Carg, lpeg.Cmt +local p_whitespace = lpegpatterns.whitespace + local trace = false trackers.register("publications", function(v) trace = v end) local report = logs.reporter("publications") @@ -85,7 +87,7 @@ local defaultshortcuts = { dec = "12", } -local space = lpeg.patterns.whitespace^0 +local space = p_whitespace^0 local separator = space * "+" * space local l_splitter = lpeg.tsplitat(separator) local d_splitter = lpeg.splitat (separator) @@ -281,10 +283,19 @@ local function resolve(s,dataset) return dataset.shortcuts[s] or defaultshortcuts[s] or s -- can be number end -local function showmessage(s) - local t = string.splitlines(utilities.strings.striplines(s)) - for i=1,#t do - report("message: %s",t[i]) +local pattern = p_whitespace^0 + * C(P("message") + P("warning") + P("error") + P("comment")) * p_whitespace^0 * P(":") + * p_whitespace^0 + * C(P(1)^1) + +local function do_comment(s,dataset) + local how, what = lpegmatch(pattern,s) + if how and what then + local t = string.splitlines(utilities.strings.striplines(what)) + local b = file.basename(dataset.fullname or dataset.name or "unset") + for i=1,#t do + report("%s > %s : %s",b,how,t[i]) + end end end @@ -303,7 +314,7 @@ local space = S(" \t\n\r\f") -- / " " local spacing = space^0 local equal = P("=") ----- collapsed = (space^1)/ " " -local collapsed = (lpegpatterns.whitespace^1)/" " +local collapsed = (p_whitespace^1)/" " ----- balanced = lpegpatterns.balanced @@ -340,18 +351,11 @@ local spacing = spacing * forget^0 * spacing local assignment = spacing * key * spacing * equal * spacing * value * spacing local definition = category * spacing * left * spacing * tag * spacing * comma * Ct((assignment * comma^0)^0) * spacing * right * Carg(1) / do_definition --- local shortcut = (P("string") + P("STRING") + P("String")) * spacing * left * ((assignment * Carg(1))/do_shortcut * comma^0)^0 * spacing * right --- local comment = (P("comment") + P("COMMENT") + P("Comment")) * spacing * lpeg.patterns.nestedbraces --- local message = (P("message") + P("MESSAGE") + P("Message")) * spacing * lpeg.patterns.argument / showmessage - --- local bibtotable = (space + forget + P("@") * (shortcut + comment + message + definition) + 1)^0 - local crapword = C((1-space-left)^1) local shortcut = Cmt(crapword,function(_,p,s) return lower(s) == "string" and p end) * spacing * left * ((assignment * Carg(1))/do_shortcut * comma^0)^0 * spacing * right -local comment = Cmt(crapword,function(_,p,s) return lower(s) == "comment" and p end) * spacing * lpeg.patterns.nestedbraces -local message = Cmt(crapword,function(_,p,s) return lower(s) == "message" and p end) * spacing * lpeg.patterns.argument / showmessage +local comment = Cmt(crapword,function(_,p,s) return lower(s) == "comment" and p end) * spacing * lpegpatterns.argument * Carg(1) / do_comment -local casecrap = #S("sScCmM") * (shortcut + comment + message) +local casecrap = #S("sScC") * (shortcut + comment) local bibtotable = (space + forget + P("@") * (casecrap + definition) + 1)^0 diff --git a/tex/context/base/status-files.pdf b/tex/context/base/status-files.pdf Binary files differindex 977cbca7c..160bf723f 100644 --- a/tex/context/base/status-files.pdf +++ b/tex/context/base/status-files.pdf diff --git a/tex/context/base/status-lua.pdf b/tex/context/base/status-lua.pdf Binary files differindex 4734b9353..1e66ffbbc 100644 --- a/tex/context/base/status-lua.pdf +++ b/tex/context/base/status-lua.pdf diff --git a/tex/generic/context/luatex/luatex-fonts-merged.lua b/tex/generic/context/luatex/luatex-fonts-merged.lua index 3304530a0..5639aa0c3 100644 --- a/tex/generic/context/luatex/luatex-fonts-merged.lua +++ b/tex/generic/context/luatex/luatex-fonts-merged.lua @@ -1,6 +1,6 @@ -- merged file : luatex-fonts-merged.lua -- parent file : luatex-fonts.lua --- merge date : 10/20/14 19:02:32 +-- merge date : 10/20/14 19:31:06 do -- begin closure to overcome local limits and interference |