Reduced to a single tex_template file

This commit is contained in:
Grant Sanderson
2018-08-13 15:17:53 -07:00
parent 7133ca8721
commit 148469486c
3 changed files with 5 additions and 29 deletions

View File

@ -135,12 +135,13 @@ for folder in [FILE_DIR, RASTER_IMAGE_DIR, SVG_IMAGE_DIR, ANIMATIONS_DIR, TEX_DI
os.makedirs(folder)
TEX_TEXT_TO_REPLACE = "YourTextHere"
TEMPLATE_TEX_FILE = os.path.join(THIS_DIR, "template.tex")
TEMPLATE_TEXT_FILE = os.path.join(THIS_DIR, "text_template.tex")
TEMPLATE_TEX_FILE = os.path.join(THIS_DIR, "tex_template.tex")
with open(TEMPLATE_TEX_FILE, "r") as infile:
TEMPLATE_TEX_FILE_BODY = infile.read()
with open(TEMPLATE_TEXT_FILE, "r") as infile:
TEMPLATE_TEXT_FILE_BODY = infile.read()
TEMPLATE_TEX_FILE_BODY = TEMPLATE_TEXT_FILE_BODY.replace(
TEX_TEXT_TO_REPLACE,
"$${}$$".format(TEX_TEXT_TO_REPLACE)
)
FFMPEG_BIN = "ffmpeg"