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

Unified Diff: git_cl.py

Issue 1579423004: git cl try: load trybot list from cq.cfg by default. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: Created 4 years, 11 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 | « commit_queue.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: git_cl.py
diff --git a/git_cl.py b/git_cl.py
index 49bed386baa821cfedf4370030bc9cb1b6afb452..e99509f1954776fc31fdf2996b0d18b7a9b234eb 100755
--- a/git_cl.py
+++ b/git_cl.py
@@ -42,6 +42,7 @@ import auth
from luci_hacks import trigger_luci_job as luci_trigger
import breakpad # pylint: disable=W0611
import clang_format
+import commit_queue
Sergiy Byelozyorov 2016/01/13 14:53:18 not sure it's a good idea. this file is designed t
tandrii(chromium) 2016/01/13 15:16:36 well, same thing with clang_format, which is also
import dart_format
import fix_encoding
import gclient_utils
@@ -3205,6 +3206,24 @@ def CMDtry(parser, args):
None,
options.verbose,
sys.stdout)
+
+ if not options.bot:
+ # Get try masters from cq.cfg if any.
+ # TODO(tandrii): some (but very few) projects store cq.cfg in different
+ # location.
+ cq_cfg = os.path.join(change.RepositoryRoot(),
+ 'infra', 'config', 'cq.cfg')
smut 2016/01/25 21:16:38 You can't hard code this path. Downstream iOS's cq
tandrii(chromium) 2016/01/26 11:41:33 what do you mean I can't? I sure can and just did
+ if os.path.exists(cq_cfg):
+ masters = {}
+ cq_masters = commit_queue.get_master_builder_map(cq_cfg)
+ for master, builders in cq_masters.iteritems():
+ for builder in builders:
+ # Skip presubmit builders, because these will fail without LGTM.
+ if 'presubmit' not in builder.lower():
+ masters.setdefault(master, {})[builder] = ['defaulttests']
+ if masters:
+ return masters
+
if not options.bot:
parser.error('No default try builder to try, use --bot')
« no previous file with comments | « commit_queue.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698