From 10a48a2cfa89285e5f1648d1241fe1019d0d56a2 Mon Sep 17 00:00:00 2001
From: Robert Alessi <alessi@robertalessi.net>
Date: Sun, 21 Apr 2019 12:55:23 +0200
Subject: specify the variant encoding method. pass '--output-xml yes' to tidy

---
 ekdosis.dtx | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

(limited to 'ekdosis.dtx')

diff --git a/ekdosis.dtx b/ekdosis.dtx
index 5cae271..8a6cbb7 100644
--- a/ekdosis.dtx
+++ b/ekdosis.dtx
@@ -912,6 +912,9 @@ function ekdosis.openteistream()
    f:write('<?xml version="1.0" encoding="utf-8"?>', "\n")
    f:write("<TEI xmlns=\"http://www.tei-c.org/ns/1.0\">", "\n")
    f:write("<teiHeader>", "\n")
+   f:write("<encodingDesc>", "\n")
+   f:write('<variantEncoding method="parallel-segmentation" location="internal"/>', "\n")
+   f:write("</encodingDesc>", "\n")
    f:write("<listWit>", "\n")
    for i = 1,#listWit do
       f:write("<msDesc xml:id=\"", listWit[i].xmlid, "\">", "\n")
@@ -999,7 +1002,7 @@ function ekdosis.closeteistream(opt)
    os.remove(teifilename..".xml")
    os.rename(teifilename.."_tmp.xml", teifilename..".xml")
    if opt == "tidy" then
-      os.execute("tidy -qmi -xml "..teifilename..".xml")
+      os.execute("tidy -qmi -xml --output-xml yes "..teifilename..".xml")
    else
    end
    return true
-- 
cgit v1.2.3

