From 12c5fc610c44f1280f2ad3830aba04dcd3187515 Mon Sep 17 00:00:00 2001 From: Matej Focko Date: Mon, 8 Jun 2020 18:05:05 +0200 Subject: [PATCH] Reformat files --- commands/comments.py | 10 +++++----- commands/merge_requests.py | 4 +++- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/commands/comments.py b/commands/comments.py index 6596cd4..101fcef 100644 --- a/commands/comments.py +++ b/commands/comments.py @@ -51,7 +51,7 @@ class Comments(BaseCommand): for file_path in comments[author]: if file_path is not None: - filename = file_path.split('/')[-1] + filename = file_path.split("/")[-1] print(f"\n`{filename}`\n{'-'*(len(filename) + 2)}") for comment in comments[author][file_path]: if comment["system"]: @@ -59,12 +59,12 @@ class Comments(BaseCommand): if comment["type"] == "DiffNote": body = comment["body"].replace( - "\n", "\n" + " " * (len(str(comment["position"]["new_line"])) + 5) + "\n", + "\n" + + " " * (len(str(comment["position"]["new_line"])) + 5), ) - print( - f"""- L{comment["position"]["new_line"]}: {body}""" - ) + print(f"""- L{comment["position"]["new_line"]}: {body}""") else: print(f"""[{comment["created_at"]}]\n{comment["body"]}""") print(header) diff --git a/commands/merge_requests.py b/commands/merge_requests.py index 667c87d..7fc2a7e 100644 --- a/commands/merge_requests.py +++ b/commands/merge_requests.py @@ -57,6 +57,8 @@ class MergeRequests(BaseGitCommand): remove_source_branch="true", assignee_ids=["1772"], ) - mr.comment(body="Summary\n=======\n\n# TODO\n\nDiff notes\n==========\n\n# TODO\n\nCorrection (YYYY/MM/DD)\n=======================\n\n# TODO") + mr.comment( + body="Summary\n=======\n\n# TODO\n\nDiff notes\n==========\n\n# TODO\n\nCorrection (YYYY/MM/DD)\n=======================\n\n# TODO" + ) except: pass