summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorMarius <mariausol@gmail.com>2012-11-17 01:00:14 +0200
committerMarius <mariausol@gmail.com>2012-11-17 01:00:14 +0200
commit055c71f6b8d7df1549ae45f9ab20a5d4e3a26c6b (patch)
tree6e2c79ae0f735b6ddcd940676656d4049c55a47d /scripts
parent4f08d2072378de7bac2c7992876b8f7012f7be78 (diff)
downloadcontext-055c71f6b8d7df1549ae45f9ab20a5d4e3a26c6b.tar.gz
beta 2012.11.16 23:51
Diffstat (limited to 'scripts')
-rw-r--r--scripts/context/lua/mtx-patterns.lua13
1 files changed, 13 insertions, 0 deletions
diff --git a/scripts/context/lua/mtx-patterns.lua b/scripts/context/lua/mtx-patterns.lua
index a436b0157..86f63bb16 100644
--- a/scripts/context/lua/mtx-patterns.lua
+++ b/scripts/context/lua/mtx-patterns.lua
@@ -16,6 +16,7 @@ local helpinfo = [[
--check check pattern file (or those used by context when no file given)
--path source path where hyph-foo.tex files are stored
--destination destination path
+--specification additional patterns: e.g.: =cy,hyph-cy,welsh
examples of usage:
@@ -454,7 +455,19 @@ function scripts.patterns.save(destination,mnemonic,name,patternsnew,hyphenation
end
function scripts.patterns.prepare()
+ --
dofile(resolvers.findfile("char-def.lua"))
+ --
+ local specification = environment.argument("specification")
+ if specification then
+ local components = utilities.parsers.settings_to_array(specification)
+ if #components == 3 then
+ table.insert(scripts.patterns.list,1,components)
+ report("specification added: %s %s %s",table.unpack(components))
+ else
+ report('invalid specification: %q, "xx,lang-yy,zzzz" expected',specification)
+ end
+ end
end
function scripts.patterns.check()