From cc67c8d7d4a07e4611a02063e9761714c1394db0 Mon Sep 17 00:00:00 2001 From: Liang-Chi Hsieh Date: Mon, 6 Aug 2018 22:13:51 +0000 Subject: [PATCH] Add manually given primary author at the head of author list. --- dev/merge_spark_pr.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dev/merge_spark_pr.py b/dev/merge_spark_pr.py index e04b6a7888d05..300795624a029 100755 --- a/dev/merge_spark_pr.py +++ b/dev/merge_spark_pr.py @@ -142,6 +142,9 @@ def merge_pr(pr_num, target_ref, title, body, pr_repo_desc): distinct_authors[0]) if primary_author == "": primary_author = distinct_authors[0] + else: + # When primary author is specified manually, put it at the head of author list. + distinct_authors.insert(0, primary_author) commits = run_cmd(['git', 'log', 'HEAD..%s' % pr_branch_name, '--pretty=format:%h [%an] %s']).split("\n\n")