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

Side by Side Diff: ios/patch_locale.sh

Issue 2743123002: ICU data customization for iOS (Closed)
Patch Set: update BUILD.gn and icudtl.dat for iOS Created 3 years, 7 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 unified diff | Download patch
« no previous file with comments | « ios/icudtl.dat ('k') | scripts/copy_data.sh » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 #!/bin/sh
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
4 # found in the LICENSE file.
5
6 treeroot="$(dirname "$0")/.."
7 cd "${treeroot}"
8
9 cd source/data
10
11 # Keep only two common calendars. Add locale-specific calendars to Thai.
12 COMMON_CALENDARS="gregorian|generic"
13 for i in locales/*.txt; do
14 CALENDARS="${COMMON_CALENDARS}"
15 case $(basename $i .txt | sed 's/_.*$//') in
16 th)
17 EXTRA_CAL='buddhist'
18 ;;
19 *)
20 EXTRA_CAL=''
21 ;;
22 esac
23
24 CAL_PATTERN="(${COMMON_CALENDARS}${EXTRA_CAL:+|${EXTRA_CAL}})"
25 echo $CAL_PATTERN
26
27 echo Overwriting $i...
28 sed -r '/^ calendar\{$/,/^ \}$/ {
29 /^ calendar\{$/p
30 /^ default\{".*"\}$/p
31 /^ '${CAL_PATTERN}'\{$/, /^ \}$/p
32 /^ \}$/p
33 d
34 }' -i $i
35 done
36
37 echo DONE.
OLDNEW
« no previous file with comments | « ios/icudtl.dat ('k') | scripts/copy_data.sh » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698