Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(141)

Side by Side Diff: git_cl.py

Issue 13513002: Fix a case branch...rietveldissue is None. (Closed) Base URL: http://git.chromium.org/chromium/tools/depot_tools.git@master
Patch Set: Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 # Copyright (C) 2008 Evan Martin <martine@danga.com> 6 # Copyright (C) 2008 Evan Martin <martine@danga.com>
7 7
8 """A git-command for integrating reviews on Rietveld.""" 8 """A git-command for integrating reviews on Rietveld."""
9 9
10 import json 10 import json
(...skipping 1275 matching lines...) Expand 10 before | Expand all | Expand 10 after
1286 verbose=options.verbose, 1286 verbose=options.verbose,
1287 change=change) 1287 change=change)
1288 if not hook_results.should_continue(): 1288 if not hook_results.should_continue():
1289 return 1 1289 return 1
1290 if not options.reviewers and hook_results.reviewers: 1290 if not options.reviewers and hook_results.reviewers:
1291 options.reviewers = hook_results.reviewers 1291 options.reviewers = hook_results.reviewers
1292 1292
1293 if cl.GetIssue(): 1293 if cl.GetIssue():
1294 latest_patchset = cl.GetMostRecentPatchset(cl.GetIssue()) 1294 latest_patchset = cl.GetMostRecentPatchset(cl.GetIssue())
1295 local_patchset = cl.GetPatchset() 1295 local_patchset = cl.GetPatchset()
1296 if local_patchset != latest_patchset: 1296 if latest_patchset and local_patchset and local_patchset != latest_patchset:
1297 print ('The last upload made from this repository was patchset #%d but ' 1297 print ('The last upload made from this repository was patchset #%d but '
1298 'the most recent patchset on the server is #%d.' 1298 'the most recent patchset on the server is #%d.'
1299 % (local_patchset, latest_patchset)) 1299 % (local_patchset, latest_patchset))
1300 ask_for_data('About to upload; enter to confirm.') 1300 ask_for_data('About to upload; enter to confirm.')
1301 1301
1302 print_stats(options.similarity, options.find_copies, args) 1302 print_stats(options.similarity, options.find_copies, args)
1303 if settings.GetIsGerrit(): 1303 if settings.GetIsGerrit():
1304 return GerritUpload(options, args, cl) 1304 return GerritUpload(options, args, cl)
1305 ret = RietveldUpload(options, args, cl) 1305 ret = RietveldUpload(options, args, cl)
1306 if not ret: 1306 if not ret:
(...skipping 594 matching lines...) Expand 10 before | Expand all | Expand 10 after
1901 'and retry or visit go/isgaeup.\n%s') % (e.code, str(e))) 1901 'and retry or visit go/isgaeup.\n%s') % (e.code, str(e)))
1902 1902
1903 # Not a known command. Default to help. 1903 # Not a known command. Default to help.
1904 GenUsage(parser, 'help') 1904 GenUsage(parser, 'help')
1905 return CMDhelp(parser, argv) 1905 return CMDhelp(parser, argv)
1906 1906
1907 1907
1908 if __name__ == '__main__': 1908 if __name__ == '__main__':
1909 fix_encoding.fix_encoding() 1909 fix_encoding.fix_encoding()
1910 sys.exit(main(sys.argv[1:])) 1910 sys.exit(main(sys.argv[1:]))
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698