diff options
author | Hans Hagen <pragma@wxs.nl> | 2014-09-06 20:59:00 +0200 |
---|---|---|
committer | Hans Hagen <pragma@wxs.nl> | 2014-09-06 20:59:00 +0200 |
commit | 02d4d3cbde5e1e94e056cdf3b732145a37413fdb (patch) | |
tree | 8a3e330fcb80df51ac91b317e7c96bf7ccad122d /scripts | |
parent | 9ae8cd92650ca8d0153d663b8fdba4c04c7fd588 (diff) | |
download | context-02d4d3cbde5e1e94e056cdf3b732145a37413fdb.tar.gz |
beta 2014.09.06 20:59
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/context/lua/mtx-epub.lua | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/scripts/context/lua/mtx-epub.lua b/scripts/context/lua/mtx-epub.lua index 2af21990d..a15058e4d 100644 --- a/scripts/context/lua/mtx-epub.lua +++ b/scripts/context/lua/mtx-epub.lua @@ -133,6 +133,8 @@ local t_toc = [[ <ncx xmlns="http://www.daisy.org/z3986/2005/ncx/" version="2005-1"> <head> + <meta charset="utf-8" /> + <meta name="generator" content="ConTeXt MkIV" /> <meta name="dtb:uid" content="%identifier%" /> <meta name="dtb:depth" content="2" /> @@ -165,6 +167,7 @@ local t_navtoc = [[ <html xmlns="http://www.w3.org/1999/xhtml" xmlns:epub="http://www.idpf.org/2007/ops"> <head> + <meta charset="utf-8" /> <title>navtoc</title> </head> <body> @@ -188,6 +191,7 @@ local t_coverxhtml = [[ <html xmlns="http://www.w3.org/1999/xhtml"> <head> + <meta charset="utf-8" /> <title>cover page</title> </head> <body> @@ -489,8 +493,16 @@ function scripts.epub.make() lfs.chdir("..") + local treefile = file.join(epubpath,epubfile) + + os.remove(epubfile) + file.copy(treefile,epubfile) + if lfs.isfile(epubfile) then + os.remove(treefile) + end + if done then - application.report("epub archive made using %s: %s",done,file.join(epubpath,epubfile)) + application.report("epub archive made using %s: %s",done,epubfile) else local list = { } for i=1,#zippers do |