From bdeabc39b23d7ed6bb0e0ea4573d85e139c49709 Mon Sep 17 00:00:00 2001 From: Zed <601306339@qq.com> Date: Tue, 30 Nov 2021 17:43:29 +0800 Subject: [PATCH] update --- scripts/release_helper/common.py | 6 ++++++ scripts/release_helper/go.py | 4 ++-- scripts/release_helper/js.py | 4 ++-- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/scripts/release_helper/common.py b/scripts/release_helper/common.py index dd5d1505f366..e9c3c1db54eb 100644 --- a/scripts/release_helper/common.py +++ b/scripts/release_helper/common.py @@ -7,6 +7,7 @@ import time from github import Github from github.Repository import Repository +import subprocess as sp _LOG = logging.getLogger(__name__) @@ -247,6 +248,10 @@ def output_python(self, item): self.date_from_target ) + def push_md_to_storage(self): + cmd_list = ['git add .', 'git commit -m \"update excel\"', 'git push -f origin HEAD'] + [sp.check_call(cmd, shell=True) for cmd in cmd_list] + def run(self): items = [] for item in self.issues_package: @@ -257,6 +262,7 @@ def run(self): except Exception as e: _LOG.error(f'Error happened during handling issue {item.issue.number}: {e}') self.output_python_md(items) + self.push_md_to_storage() def common_process(issues: List[IssuePackage]): diff --git a/scripts/release_helper/go.py b/scripts/release_helper/go.py index 5d17ddf56ecf..61464dd1c681 100644 --- a/scripts/release_helper/go.py +++ b/scripts/release_helper/go.py @@ -14,8 +14,8 @@ class IssueProcessGo(IssueProcess): class Go(Common): - def __init__(self): - super(Go, self).__init__() + def __init__(self, issues, assignee_token, language_owner): + super(Go, self).__init__(issues, assignee_token, language_owner) self.file_out_name = 'release_go_status.md' diff --git a/scripts/release_helper/js.py b/scripts/release_helper/js.py index 9139d8adce73..4792a38336fd 100644 --- a/scripts/release_helper/js.py +++ b/scripts/release_helper/js.py @@ -14,8 +14,8 @@ class IssueProcessJs(IssueProcess): class Js(Common): - def __init__(self): - super(Js, self).__init__() + def __init__(self, issues, assignee_token, language_owner): + super(Js, self).__init__(issues, assignee_token, language_owner) self.file_out_name = 'release_js_status.md'