@check_current_directory<EOL><INDENT>def build(self):<DEDENT>
config = self.load_config()<EOL>html_generator = HTMLGenerator(self.cwd, config)<EOL>html_generator.build()<EOL>if self.args.get('<STR_LIT>', None):<EOL><INDENT>generator = self.args.get('<STR_LIT>')<EOL><DEDENT>else:<EOL><INDENT>generator = config.get('<STR_LIT>')<EOL><DEDENT>if generator == '<STR_LIT>':<EOL><INDENT>EPUBClass = CalibreEPUBGenerator<EOL>PDFClass = CalibrePDFGenerator<EOL><DEDENT>elif generator == '<STR_LIT>':<EOL><INDENT>EPUBClass = PandocEPUBGenerator<EOL>PDFClass = PandocPDFGenerator<EOL><DEDENT>else:<EOL><INDENT>raise ConfigurationError(<EOL>"<STR_LIT>")<EOL><DEDENT>epub_generator = EPUBClass(self.cwd, config, self.args)<EOL>epub_generator.build()<EOL>if config.get('<STR_LIT>', False) or self.args['<STR_LIT>']:<EOL><INDENT>pdf_generator = PDFClass(self.cwd, config, self.args)<EOL>pdf_generator.build()<EOL><DEDENT>
Build your book