| OLD | NEW |
| 1 # Copyright 2013 The Chromium Authors. All rights reserved. | 1 # Copyright 2013 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 changes affecting chrome/app/ | 5 """Presubmit script for changes affecting chrome/app/ |
| 6 | 6 |
| 7 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts | 7 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts |
| 8 for more details about the presubmit API built into gcl. | 8 for more details about the presubmit API built into depot_tools. |
| 9 """ | 9 """ |
| 10 | 10 |
| 11 import os | 11 import os |
| 12 | 12 |
| 13 def _CheckNoProductNameInGeneratedResources(input_api, output_api): | 13 def _CheckNoProductNameInGeneratedResources(input_api, output_api): |
| 14 """Check that no PRODUCT_NAME placeholders are found in resources files. | 14 """Check that no PRODUCT_NAME placeholders are found in resources files. |
| 15 | 15 |
| 16 These kinds of strings prevent proper localization in some languages. For | 16 These kinds of strings prevent proper localization in some languages. For |
| 17 more information, see the following chromium-dev thread: | 17 more information, see the following chromium-dev thread: |
| 18 https://groups.google.com/a/chromium.org/forum/#!msg/chromium-dev/PBs5JfR0Aoc/
NOcIHII9u14J | 18 https://groups.google.com/a/chromium.org/forum/#!msg/chromium-dev/PBs5JfR0Aoc/
NOcIHII9u14J |
| (...skipping 19 matching lines...) Expand all Loading... |
| 38 """Checks common to both upload and commit.""" | 38 """Checks common to both upload and commit.""" |
| 39 results = [] | 39 results = [] |
| 40 results.extend(_CheckNoProductNameInGeneratedResources(input_api, output_api)) | 40 results.extend(_CheckNoProductNameInGeneratedResources(input_api, output_api)) |
| 41 return results | 41 return results |
| 42 | 42 |
| 43 def CheckChangeOnUpload(input_api, output_api): | 43 def CheckChangeOnUpload(input_api, output_api): |
| 44 return _CommonChecks(input_api, output_api) | 44 return _CommonChecks(input_api, output_api) |
| 45 | 45 |
| 46 def CheckChangeOnCommit(input_api, output_api): | 46 def CheckChangeOnCommit(input_api, output_api): |
| 47 return _CommonChecks(input_api, output_api) | 47 return _CommonChecks(input_api, output_api) |
| OLD | NEW |