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

Unified Diff: rietveld.py

Issue 2127633003: Implement git cl set-commit --dry-run for Rietveld. (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/depot_tools.git@master
Patch Set: be consistent Created 4 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « git_cl.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: rietveld.py
diff --git a/rietveld.py b/rietveld.py
index 028b0b00d8ea3d20d7bd729f6b3a0f700ac95d51..bd9139182e5754f99e2990633fb216fbfb2a9282 100644
--- a/rietveld.py
+++ b/rietveld.py
@@ -278,6 +278,12 @@ class Rietveld(object):
('xsrf_token', self.xsrf_token()),
(flag, str(value))])
+ def set_flags(self, issue, patchset, flags):
+ return self.post('/%d/edit_flags' % issue, [
+ ('last_patchset', str(patchset)),
+ ('xsrf_token', self.xsrf_token()),
+ ] + [(flag, str(value)) for flag, value in flags.iteritems()])
+
def search(
self,
owner=None, reviewer=None,
@@ -744,6 +750,10 @@ class ReadOnlyRietveld(object):
(flag, value, issue))
ReadOnlyRietveld._local_changes.setdefault(issue, {})[flag] = value
+ def set_flags(self, issue, patchset, flags):
+ for flag, value in flags.iteritems():
+ self.set_flag(issue, patchset, flag, value)
+
def trigger_try_jobs( # pylint:disable=R0201
self, issue, patchset, reason, clobber, revision, builders_and_tests,
master=None, category='cq'):
« no previous file with comments | « git_cl.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698