-
Notifications
You must be signed in to change notification settings - Fork 0
/
PRESUBMIT.py
executable file
·30 lines (24 loc) · 1.02 KB
/
PRESUBMIT.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# Copyright (c) 2011 The Native Client Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
# Documentation on PRESUBMIT.py can be found at:
# http://www.chromium.org/developers/how-tos/depottools/presubmit-scripts
_EXCLUDED_PATHS = (
# patch_configure.py contains long lines embedded in multi-line
# strings.
r"^build_tools[\\\/]patch_configure.py",
)
def CheckChangeOnUpload(input_api, output_api):
report = []
affected_files = input_api.AffectedFiles(include_deletes=False)
report.extend(input_api.canned_checks.PanProjectChecks(
input_api, output_api, project_name='Native Client',
excluded_paths=_EXCLUDED_PATHS))
return report
def CheckChangeOnCommit(input_api, output_api):
report = []
report.extend(CheckChangeOnUpload(input_api, output_api))
report.extend(input_api.canned_checks.CheckTreeIsOpen(
input_api, output_api,
json_url='http://naclports-status.appspot.com/current?format=json'))
return report