Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tools/icu
diff options
context:
space:
mode:
authorSteven R. Loomis <srloomis@us.ibm.com>2020-03-18 20:42:06 +0300
committerSteven R. Loomis <srloomis@us.ibm.com>2020-03-21 03:21:50 +0300
commitb8a794d72bad66f25ce645d08defb41bd57c3371 (patch)
treea2a94eb9bdb44c3d243ea34265ecc3edaa25b65d /tools/icu
parent131b50d1878924291e4a7e3304e180494d5a3e0f (diff)
deps: minor ICU fixes: maint docs/tool, downloader
- Docs used the word "copy" when it really meant a tool is needed. - README-FULL-ICU.txt was generated in binary mode, but it's a text file. This breaks on Python3 for maintaining ICU - The ICU downloader was broken (also probably python3). It's basically dead code since 1a25e901b7c380929f0d08599f49dd77897a627f landed (full icu in repo), unless someone deleted the deps/icu-small directory from their repo. Co-Authored-By: Christian Clauss <cclauss@me.com> PR-URL: https://github.com/nodejs/node/pull/32347 Reviewed-By: Ujjwal Sharma <ryzokuken@disroot.org> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Christian Clauss <cclauss@me.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Diffstat (limited to 'tools/icu')
-rw-r--r--tools/icu/shrink-icu-src.py20
1 files changed, 9 insertions, 11 deletions
diff --git a/tools/icu/shrink-icu-src.py b/tools/icu/shrink-icu-src.py
index c91472ed308..3a9ba2fbfbf 100644
--- a/tools/icu/shrink-icu-src.py
+++ b/tools/icu/shrink-icu-src.py
@@ -128,14 +128,12 @@ print_size(dst_cmp_datafile)
readme_name = os.path.join(options.icudst, "README-FULL-ICU.txt" )
# Now, print a short notice
-fi = open(readme_name, 'wb')
-print("ICU sources - auto generated by shrink-icu-src.py", file=fi)
-print("", file=fi)
-print("This directory contains the ICU subset used by --with-intl=full-icu", file=fi)
-print("It is a strict subset of ICU %s source files with the following exception(s):" % (icu_ver_major), file=fi)
-print("* %s : compressed data file" % (dst_cmp_datafile), file=fi)
-print("", file=fi)
-print("", file=fi)
-print("To rebuild this directory, see ../../tools/icu/README.md", file=fi)
-print("", file=fi)
-fi.close()
+msg_fmt = """\
+ICU sources - auto generated by shrink-icu-src.py\n
+This directory contains the ICU subset used by --with-intl=full-icu
+It is a strict subset of ICU {} source files with the following exception(s):
+* {} : compressed data file\n\n
+To rebuild this directory, see ../../tools/icu/README.md\n"""
+
+with open(readme_name, 'w') as out_file:
+ print(msg_fmt.format(icu_ver_major, dst_cmp_datafile), file=out_file)