doc: update
This commit is contained in:
+10
-8
@@ -53,6 +53,7 @@ def __doc_application__(label, app):
|
||||
def document(fname, args, config):
|
||||
"""Document MARTe object."""
|
||||
doc.set_path(os.path.join(args.destination, fname))
|
||||
doc.set_config(args)
|
||||
if not os.path.isdir(doc.path()):
|
||||
os.mkdir(doc.path())
|
||||
now = datetime.now() # current date and time
|
||||
@@ -79,11 +80,12 @@ def document(fname, args, config):
|
||||
logging.info(f"Saving markdown: {fpath}")
|
||||
with open(fpath, "w") as file:
|
||||
file.write(mddoc)
|
||||
logging.info(f"Generating html: {outpath}.html")
|
||||
os.system(
|
||||
f"pandoc --css pandoc/styling.css --resource-path={doc.path()} --embed-resource --to html5 -s {fpath} -o {outpath}.html"
|
||||
)
|
||||
logging.info(f"Generating pdf: {outpath}.pdf")
|
||||
os.system(
|
||||
f"pandoc -H pandoc/disable_float.tex --resource-path={doc.path()} -s {fpath} -o {outpath}.pdf"
|
||||
)
|
||||
if doc.build():
|
||||
logging.info(f"Generating html: {outpath}.html")
|
||||
os.system(
|
||||
f"pandoc --css pandoc/styling.css --resource-path={doc.path()} --embed-resource --to html5 -s {fpath} -o {outpath}.html"
|
||||
)
|
||||
logging.info(f"Generating pdf: {outpath}.pdf")
|
||||
os.system(
|
||||
f"pandoc -H pandoc/disable_float.tex --resource-path={doc.path()} -s {fpath} -o {outpath}.pdf"
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user