Created
July 30, 2011 12:41
-
-
Save whs/1115484 to your computer and use it in GitHub Desktop.
WMC Renderer
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from jinja2 import Environment, FileSystemLoader | |
| from glob import glob | |
| from os.path import basename | |
| env = Environment(loader=FileSystemLoader('template')) | |
| for i in glob("template/*.j.html"): | |
| output = env.get_template(basename(i)).render() | |
| open("output/" + basename(i).replace(".j.html", ".html"), "w").write(output) |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Usage: