e.printStackTrace();
System.exit(-1);
}
}
RegexConfigurator conf = new RegexConfigurator();
if (latex) {
List<Tag> tags = conf.read("/regex.properties", "/latex.properties");
Parser parser = new LatexParser(tags, showNotes, noAnswer);
LatexGenerator generator = new LatexGenerator(parser, templateDir, noAnswer);
File file = new File(outputDir, "latex");
FileUtils.forceMkdir(file);
try {
generator.generate(b, file, outputFileName);
} catch (TubainaException e) {
LOG.warn(e.getMessage());
}
}
if (html) {
HtmlParser htmlParser = new HtmlParser(conf.read("/regex.properties", "/html.properties"), noAnswer);
HtmlGenerator generator = new HtmlGenerator(htmlParser, strictXhtml, templateDir);
File file = new File(outputDir, "html");
FileUtils.forceMkdir(file);
try {
generator.generate(b, file);