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

Unified Diff: scripts/update_tz.sh

Issue 1051193002: Update tz db to 2015b (Closed) Base URL: https://chromium.googlesource.com/chromium/deps/icu.git@master
Patch Set: add comments to update_tz.sh Created 5 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: scripts/update_tz.sh
diff --git a/scripts/update_tz.sh b/scripts/update_tz.sh
new file mode 100644
index 0000000000000000000000000000000000000000..f5b77e7257811d2c5466c653fb67119dc14090b4
--- /dev/null
+++ b/scripts/update_tz.sh
@@ -0,0 +1,27 @@
+#!/bin/bash
+# Copyright (c) 2015 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+# Download the 4 files below from the ICU respos and put them in
Mark Mentovai 2015/04/02 19:47:10 respos?
jungshik at Google 2015/04/02 21:21:05 Changed it to 'the ICU data repository' and added
+# source/data/misc to update the IANA timezone database in ICU.
+#
+# metaZones.txt timezoneTypes.txt windowsZones.txt zoneinfo64.txt
+#
+# For IANA Time zone database, set https://www.iana.org/time-zones
Mark Mentovai 2015/04/02 19:47:10 see instead of set?
jungshik at Google 2015/04/02 21:21:05 Done.
+
+if [ $# -lt 1 ];
+then
+ echo "Usage: $0 version (e.g. '2015b')"
+ exit 1
+fi
+
+version=$1
+baseurl="http://source.icu-project.org/repos/icu/data/trunk/tzdata/icunew/"
+outputdir="$(dirname $0)/../source/data/misc"
Mark Mentovai 2015/04/02 19:47:10 "$0"
jungshik at Google 2015/04/02 21:21:05 Done.
+
+
+for f in metaZones.txt timezoneTypes.txt windowsZones.txt zoneinfo64.txt
+do
+ wget -O "${outputdir}/${f}" "${baseurl}/${version}/44/${f}"
Mark Mentovai 2015/04/02 19:47:10 44 seems magic. Is it a version number? Will it ev
jungshik at Google 2015/04/02 21:21:05 Make it a variable and added an explanation.
+done

Powered by Google App Engine
This is Rietveld 408576698