summaryrefslogtreecommitdiff
path: root/scripts/context/lua/mtx-epub.lua
diff options
context:
space:
mode:
authorMarius <mariausol@gmail.com>2013-03-21 15:00:17 +0200
committerMarius <mariausol@gmail.com>2013-03-21 15:00:17 +0200
commit6bb39561d4571fb85aac56a686b837a9f3c910cd (patch)
tree87f9b55ac771b742532fec258c637c0b15ec7dae /scripts/context/lua/mtx-epub.lua
parent41df6a896ad3ab1d8bb6286423e9540b2b34f576 (diff)
downloadcontext-6bb39561d4571fb85aac56a686b837a9f3c910cd.tar.gz
beta 2013.03.21 13:42
Diffstat (limited to 'scripts/context/lua/mtx-epub.lua')
-rw-r--r--scripts/context/lua/mtx-epub.lua30
1 files changed, 25 insertions, 5 deletions
diff --git a/scripts/context/lua/mtx-epub.lua b/scripts/context/lua/mtx-epub.lua
index 28a37fec2..11f0a2024 100644
--- a/scripts/context/lua/mtx-epub.lua
+++ b/scripts/context/lua/mtx-epub.lua
@@ -22,11 +22,29 @@ local format, gsub = string.format, string.gsub
local concat = table.concat
local helpinfo = [[
---make create epub zip file
-
-example:
-
-mtxrun --script epub --make mydocument
+<?xml version="1.0"?>
+<application>
+ <metadata>
+ <entry name="name">mtx-epub</entry>
+ <entry name="detail">ConTeXt EPUB Helpers</entry>
+ <entry name="version">0.12</entry>
+ </metadata>
+ <flags>
+ <category name="basic">
+ <subcategory>
+ <flag name="make"><short>create epub zip file</short></flag>
+ </subcategory>
+ </category>
+ </flags>
+ <examples>
+ <category>
+ <title>Example</title>
+ <subcategory>
+ <example><command>mtxrun --script epub --make mydocument</command></example>
+ </subcategory>
+ </category>
+ </examples>
+</application>
]]
local application = logs.application {
@@ -353,6 +371,8 @@ end
if environment.argument("make") then
scripts.epub.make()
+elseif environment.argument("exporthelp") then
+ application.export(environment.argument("exporthelp"),environment.files[1])
else
application.help()
end