Skip to content

Commit

Permalink
🤕
Browse files Browse the repository at this point in the history
  • Loading branch information
riaf authored Dec 3, 2023
1 parent 7866ae9 commit b3ea9c9
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions script.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,12 @@ def parse_hugo_markdown(file_path):

return meta_dict, html_body

def parse_date(date_str):
try:
return date_parser.parse(date_str)
except ValueError:
return None

def create_guid(file_path, date):
hash_input = f"{file_path}-{date}"
return hashlib.sha256(hash_input.encode()).hexdigest()
Expand Down

0 comments on commit b3ea9c9

Please sign in to comment.