Mercurial > public > sg101
view tools/ssg101/ssg101.py @ 1200:b9514abc2a67
Initial commit of ssg101.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Sat, 24 Jun 2023 16:06:51 -0500 |
parents | |
children |
line wrap: on
line source
import jinja2 def main(): print('Hello World') env = jinja2.Environment( loader=jinja2.PackageLoader('ssg101'), ) template = env.get_template('home.html') with open('output/home.html', 'w') as fp: fp.write(template.render()) if __name__ == '__main__': main()