| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 | 5 |
| 6 """Helper script to repack paks for a list of locales. | 6 """Helper script to repack paks for a list of locales. |
| 7 | 7 |
| 8 Gyp doesn't have any built-in looping capability, so this just provides a way to | 8 Gyp doesn't have any built-in looping capability, so this just provides a way to |
| 9 loop over a list of locales when repacking pak files, thus avoiding a | 9 loop over a list of locales when repacking pak files, thus avoiding a |
| 10 proliferation of mostly duplicate, cut-n-paste gyp actions. | 10 proliferation of mostly duplicate, cut-n-paste gyp actions. |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 80 'webkit_strings_%s.pak' % locale)) | 80 'webkit_strings_%s.pak' % locale)) |
| 81 | 81 |
| 82 #e.g. '<(SHARED_INTERMEDIATE_DIR)/ui/ui_strings_da.pak', | 82 #e.g. '<(SHARED_INTERMEDIATE_DIR)/ui/ui_strings_da.pak', |
| 83 inputs.append(os.path.join(SHARE_INT_DIR, 'ui', 'ui_strings', | 83 inputs.append(os.path.join(SHARE_INT_DIR, 'ui', 'ui_strings', |
| 84 'ui_strings_%s.pak' % locale)) | 84 'ui_strings_%s.pak' % locale)) |
| 85 | 85 |
| 86 #e.g. '<(SHARED_INTERMEDIATE_DIR)/ash_strings/ash_strings_da.pak', | 86 #e.g. '<(SHARED_INTERMEDIATE_DIR)/ash_strings/ash_strings_da.pak', |
| 87 inputs.append(os.path.join(SHARE_INT_DIR, 'ash_strings', | 87 inputs.append(os.path.join(SHARE_INT_DIR, 'ash_strings', |
| 88 'ash_strings_%s.pak' % locale)) | 88 'ash_strings_%s.pak' % locale)) |
| 89 | 89 |
| 90 #e.g. '<(SHARED_INTERMEDIATE_DIR)/device_bluetooth_strings/ | 90 #e.g. '<(SHARED_INTERMEDIATE_DIR)/device/bluetooth/strings/ |
| 91 # device_bluetooth_strings_da.pak', | 91 # device_bluetooth_strings_da.pak', |
| 92 inputs.append(os.path.join(SHARE_INT_DIR, 'device_bluetooth_strings', | 92 inputs.append(os.path.join(SHARE_INT_DIR, 'device', 'bluetooth', 'strings', |
| 93 'device_bluetooth_strings_%s.pak' % locale)) | 93 'device_bluetooth_strings_%s.pak' % locale)) |
| 94 | 94 |
| 95 #e.g. '<(SHARED_INTERMEDIATE_DIR)/ui/app_locale_settings_da.pak', | 95 #e.g. '<(SHARED_INTERMEDIATE_DIR)/ui/app_locale_settings_da.pak', |
| 96 inputs.append(os.path.join(SHARE_INT_DIR, 'ui', 'app_locale_settings', | 96 inputs.append(os.path.join(SHARE_INT_DIR, 'ui', 'app_locale_settings', |
| 97 'app_locale_settings_%s.pak' % locale)) | 97 'app_locale_settings_%s.pak' % locale)) |
| 98 | 98 |
| 99 #e.g. '<(grit_out_dir)/google_chrome_strings_da.pak' | 99 #e.g. '<(grit_out_dir)/google_chrome_strings_da.pak' |
| 100 # or | 100 # or |
| 101 # '<(grit_out_dir)/chromium_strings_da.pak' | 101 # '<(grit_out_dir)/chromium_strings_da.pak' |
| 102 inputs.append(os.path.join( | 102 inputs.append(os.path.join( |
| (...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 209 | 209 |
| 210 if print_outputs: | 210 if print_outputs: |
| 211 return list_outputs(locales) | 211 return list_outputs(locales) |
| 212 | 212 |
| 213 return repack_locales(locales) | 213 return repack_locales(locales) |
| 214 | 214 |
| 215 if __name__ == '__main__': | 215 if __name__ == '__main__': |
| 216 results = DoMain(sys.argv[1:]) | 216 results = DoMain(sys.argv[1:]) |
| 217 if results: | 217 if results: |
| 218 print results | 218 print results |
| OLD | NEW |