updates
This commit is contained in:
17
hydrogen.py
17
hydrogen.py
@@ -25,7 +25,7 @@ header_image = Config.HEADER_IMAGE or '/static/header.jpg'
|
||||
|
||||
|
||||
|
||||
def build_site():
|
||||
def build_site_old():
|
||||
logger.info(f"Building the '{Config.MAIN_PAGE_TITLE}' site.")
|
||||
|
||||
# Recreate the output dir if needed
|
||||
@@ -73,14 +73,13 @@ def build_site():
|
||||
|
||||
def main():
|
||||
args = argparser.parse_args()
|
||||
if args.content:
|
||||
content = args.content or args.edit
|
||||
create_content(content)
|
||||
edit_content(content)
|
||||
if args.build:
|
||||
build_site()
|
||||
if args.init:
|
||||
init_site()
|
||||
match args.command:
|
||||
case "build":
|
||||
build_site()
|
||||
case "init":
|
||||
init_site()
|
||||
case "new" | "create" | "edit":
|
||||
edit_content(args.filename)
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
Reference in New Issue
Block a user