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

Side by Side Diff: scripts/update.sh

Issue 1566043002: Prepare for ICU upgrade to 56.1 (Closed) Base URL: https://chromium.googlesource.com/chromium/deps/icu.git@master
Patch Set: add version check Created 4 years, 11 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 | « scripts/data_files_to_preserve.txt ('k') | no next file » | 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/bash
2 # Copyright (c) 2016 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 # This is used to prepare for a major version update of ICU (e.g. from
7 # 54.1 to 56.1). Running this script is step 1 in README.chromium.
8
9 if [ $# -lt 1 ];
10 then
11 echo "Usage: $0 version (e.g. '56-1')"
12 exit 1
13 fi
14
15 version="$1"
16 repoprefix="http://source.icu-project.org/repos/icu/icu/tags/release-"
17 repo="${repoprefix}${version}"
18 treeroot="$(dirname "$0")/.."
19
20 # Check if the repo for $version is available.
21 svn ls "${repo}" > /dev/null 2>&1 || \
22 { echo "${repo} does not exist."; exit 2; }
23
24 # clean up source/ and start afresh
25 rm -rf "$treeroot/source"
26 rm -f license.html readme.html APIChangeReport.html
27
28 for file in source license.html readme.html APIChangeReport.html
29 do
30 svn export --native-eol LF "${repo}/${file}" "${treeroot}/${file}"
31 done
32
33 # delete directories we don't care about
34 for d in layout layoutex data/xml
35 do
36 rm -rf "${treeroot}/source/${d}"
37 done
38
39 # Restore local data and configuration files.
40 while read line
41 do
42 # $line is not quoted to expand "*html.ucm".
43 git checkout -- "${treeroot}/source/data/"${line}
44 done < "${treeroot}/scripts/data_files_to_preserve.txt"
45
46 # Get runConfigureICU to work without source/layout(ex) directories.
47 sed -r -i -e '/^ac_config_files=/ s:\ layout(ex)?/Makefile::g' \
Mark Mentovai 2016/01/07 18:25:32 This is GNU sed usage. This won’t work on OS X, al
48 "${treeroot}/source/configure"
OLDNEW
« no previous file with comments | « scripts/data_files_to_preserve.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698