summaryrefslogtreecommitdiffstats
path: root/tools/repopick.py
diff options
context:
space:
mode:
authorjrior001 <jriordan001@gmail.com>2015-08-21 17:23:25 -0400
committerTom Powell <zifnab@zifnab06.net>2015-10-08 15:02:54 -0700
commitfd11d07640345d4b5d550cc3c64f700c782696c0 (patch)
treea97797ff099a0d5d731079d4e51e4856b1b6df0c /tools/repopick.py
parentc8580307f2d99eb7b15dfaf9f2b0c7d3ec830666 (diff)
downloadbuild-fd11d07640345d4b5d550cc3c64f700c782696c0.zip
build-fd11d07640345d4b5d550cc3c64f700c782696c0.tar.gz
build-fd11d07640345d4b5d550cc3c64f700c782696c0.tar.bz2
repopick: skip abandoned commits
Change-Id: I7f203fc4f790bf26acce1112c5c24c703acd9326
Diffstat (limited to 'tools/repopick.py')
-rwxr-xr-xtools/repopick.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/tools/repopick.py b/tools/repopick.py
index 022cfce..f369f2b 100755
--- a/tools/repopick.py
+++ b/tools/repopick.py
@@ -139,7 +139,7 @@ if __name__ == '__main__':
parser.add_argument('-b', '--auto-branch', action='store_true', help='shortcut to "--start-branch auto --abandon-first --ignore-missing"')
parser.add_argument('-q', '--quiet', action='store_true', help='print as little as possible')
parser.add_argument('-v', '--verbose', action='store_true', help='print extra information to aid in debug')
- parser.add_argument('-f', '--force', action='store_true', help='force cherry pick even if commit has been merged')
+ parser.add_argument('-f', '--force', action='store_true', help='force cherry pick even if change is closed')
parser.add_argument('-p', '--pull', action='store_true', help='execute pull instead of cherry-pick')
parser.add_argument('-t', '--topic', help='pick all commits from a specified topic')
parser.add_argument('-Q', '--query', help='pick all commits using the specified query')
@@ -247,12 +247,12 @@ if __name__ == '__main__':
for item in mergables:
print('Applying change number {0}...'.format(item['id']))
- # Check if commit has already been merged and exit if it has, unless -f is specified
- if item['status'] == 'MERGED':
+ # Check if change is open and exit if it's not, unless -f is specified
+ if item['status'] != 'OPEN' and not args.query:
if args.force:
- print('!! Force-picking a merged commit !!\n')
+ print('!! Force-picking a closed change !!\n')
else:
- print('Commit already merged. Skipping the cherry pick.\nUse -f to force this pick.')
+ print('Change is closed. Skipping the cherry pick.\nUse -f to force this pick.')
continue
# Convert the project name to a project path