pulsar-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] ivankelly commented on a change in pull request #2526: [dev] provide a python merge script for merging pull requests
Date Thu, 06 Sep 2018 08:22:55 GMT
ivankelly commented on a change in pull request #2526: [dev] provide a python merge script
for merging pull requests
URL: https://github.com/apache/incubator-pulsar/pull/2526#discussion_r215529911
 
 

 ##########
 File path: dev/pulsar-merge-pr.py
 ##########
 @@ -0,0 +1,699 @@
+#!/usr/bin/env python
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
+# Utility for creating well-formed pull request merges and pushing them to Apache. This script
is a modified version
+# of the one created by the BookKeeper project (https://github.com/apache/bookkeeper/blob/master/dev/bk-merge-pr.py).
+#
+# Usage: ./pulsar-merge-pr.py (see config env vars below)
+#
+# This utility assumes you already have local a pulsar git folder and that you
+# have added remotes corresponding to the github apache pulsar repo.
+
+import json
+import os
+import re
+import subprocess
+import sys
+import urllib2
+
+PROJECT_NAME = "incubator-pulsar"
+
+CAPITALIZED_PROJECT_NAME = "pulsar".upper()
+GITHUB_ISSUES_NAME = "issue".upper()
+
+# Location of the local git repository
+REPO_HOME = os.environ.get("%s_HOME" % CAPITALIZED_PROJECT_NAME, os.getcwd())
+# Remote name which points to the GitHub site
+PR_REMOTE_NAME = os.environ.get("PR_REMOTE_NAME", "apache")
+# Remote name which points to Apache git
+PUSH_REMOTE_NAME = os.environ.get("PUSH_REMOTE_NAME", "apache")
 
 Review comment:
   Having PR_REMOTE_NAME and PUSH_REMOTE_NAME no longer makes sense, since github is the canonical
repo.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message