From e8f3a6fae0c4be9f547d0f50dce8a5a451701f23 Mon Sep 17 00:00:00 2001 From: kthoden Date: Tue, 19 Mar 2019 11:27:15 +0100 Subject: [PATCH 1/2] Work begun: format citations with htlatex --- libeoaconvert.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/libeoaconvert.py b/libeoaconvert.py index 3a39437..6290594 100644 --- a/libeoaconvert.py +++ b/libeoaconvert.py @@ -200,6 +200,16 @@ def plural(num, noun, plural=None): return phrase # def plural ends here + +def format_citations_tex4ht(used_citekeys, bibdata, language, tmp_filename): + """Return a formatted xmlstring of the used citations""" + + tmp_path_md = "tmp_files" + os.path.sep + tmp_filename + ".tex" + tmp_path_html = "tmp_files" + os.path.sep + tmp_filename + ".html" + + return references +# def format_citations_tex4ht ends here + def format_citations(used_citekeys, bibdata, language, tmp_filename): """Return a formatted xmlstring of the used citations""" From 474e23b26137dbb17b530b71835f47123eeeefa6 Mon Sep 17 00:00:00 2001 From: kthoden Date: Tue, 19 Mar 2019 17:45:19 +0100 Subject: [PATCH 2/2] Typo --- fix_tei.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fix_tei.py b/fix_tei.py index 1797f93..f537f37 100644 --- a/fix_tei.py +++ b/fix_tei.py @@ -361,7 +361,7 @@ def cleanup_xml(xml_tree): for attribute in xml_preserve: attribute.attrib.pop("{http://www.w3.org/XML/1998/namespace}space") - formulae = xmltree.xpath("//t:formula", namespaces=NS_MAP) + formulae = xml_tree.xpath("//t:formula", namespaces=NS_MAP) logging.info(f"Found {len(formulae)} formulae.") for formula in formulae: