def generate_tag_pages(): """ Generate "/tag/<string>" pages """ for t in _tags: tag_page_dir = os.path.join(_deploy_dir, 'tag', t) os.makedirs(tag_page_dir) with open(os.path.join(tag_page_dir, 'index.html'), 'w', encoding='utf-8') as f: f.write(handler.tag(t))
def tag(t): return handler.tag(t)