Skip to content

Commit

Permalink
only prompt if title has been modified
Browse files Browse the repository at this point in the history
  • Loading branch information
texasmichelle committed Apr 21, 2015
1 parent 8c195bb commit 7d5fa20
Showing 1 changed file with 13 additions and 9 deletions.
22 changes: 13 additions & 9 deletions dev/merge_spark_pr.py
Original file line number Diff line number Diff line change
Expand Up @@ -354,17 +354,21 @@ def main():
url = pr["url"]

# Decide whether to use the modified title or not
print "I've re-written the title as follows to match the standard format:"
print "Original: %s" % pr["title"]
print "Modified: %s" % standardize_jira_ref(pr["title"])
result = raw_input("Would you like to use the modified title? (y/n): ")
if result.lower() == "y":
title = standardize_jira_ref(pr["title"])
print "Using modified title:"
modified_title = standardize_jira_ref(pr["title"])
if modified_title != pr["title"]:
print "I've re-written the title as follows to match the standard format:"
print "Original: %s" % pr["title"]
print "Modified: %s" % modified_title
result = raw_input("Would you like to use the modified title? (y/n): ")
if result.lower() == "y":
title = modified_title
print "Using modified title:"
else:
title = pr["title"]
print "Using original title:"
print title
else:
title = pr["title"]
print "Using original title:"
print title

body = pr["body"]
target_ref = pr["base"]["ref"]
Expand Down

0 comments on commit 7d5fa20

Please sign in to comment.