Skip to content

Commit

Permalink
edit: edit workflow script
Browse files Browse the repository at this point in the history
  • Loading branch information
gogumaC committed Jun 23, 2024
1 parent 0eaa8c0 commit 4ecb475
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions requestNotionUpload.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,10 @@ def parse_commit_msg(msg,pattern):
head=lines[0]
match=re.match(pattern,head)
if match:
_, platform, level, title,lans = match.groups()
op, platform, level, title,lans = match.groups()
if op!="solve":
print(f"this commit is not about solved problem : {op}")
return
problem=Problem(
title=title,
lan=[lan for lan in lans.split('_')],
Expand Down Expand Up @@ -91,7 +94,8 @@ def parse_commit_msg(msg,pattern):
print("commit : ",COMMIT_MSG,"\n")

body=parse_commit_msg(COMMIT_MSG,PATTERN)
print(body)
result=request_notion_update(body)
if not result:
sys.exit(1)
if body:
print(body)
result=request_notion_update(body)
if not result:
sys.exit(1)

0 comments on commit 4ecb475

Please sign in to comment.