OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 """Presubmit script for Chromium browser code. | 5 """Presubmit script for Chromium browser code. |
6 | 6 |
7 This script currently only checks HTML/CSS/JS files in resources/. | 7 This script currently only checks HTML/CSS/JS files in resources/. |
8 | 8 |
9 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts | 9 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts |
10 for more details about the presubmit API built into gcl/git cl, and see | 10 for more details about the presubmit API built into depot_tools, and see |
11 http://www.chromium.org/developers/web-development-style-guide for the rules | 11 http://www.chromium.org/developers/web-development-style-guide for the rules |
12 checked for here. | 12 checked for here. |
13 """ | 13 """ |
14 | 14 |
15 | 15 |
16 def CheckChangeOnUpload(input_api, output_api): | 16 def CheckChangeOnUpload(input_api, output_api): |
17 return _CommonChecks(input_api, output_api) | 17 return _CommonChecks(input_api, output_api) |
18 | 18 |
19 | 19 |
20 def CheckChangeOnCommit(input_api, output_api): | 20 def CheckChangeOnCommit(input_api, output_api): |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 results.extend(css_checker.CSSChecker( | 66 results.extend(css_checker.CSSChecker( |
67 input_api, output_api, file_filter=is_resource).RunChecks()) | 67 input_api, output_api, file_filter=is_resource).RunChecks()) |
68 results.extend(html_checker.HtmlChecker( | 68 results.extend(html_checker.HtmlChecker( |
69 input_api, output_api, file_filter=is_resource).RunChecks()) | 69 input_api, output_api, file_filter=is_resource).RunChecks()) |
70 results.extend(js_checker.JSChecker( | 70 results.extend(js_checker.JSChecker( |
71 input_api, output_api, file_filter=is_resource).RunChecks()) | 71 input_api, output_api, file_filter=is_resource).RunChecks()) |
72 finally: | 72 finally: |
73 sys.path = old_path | 73 sys.path = old_path |
74 | 74 |
75 return results | 75 return results |
OLD | NEW |