]> granicus.if.org Git - icu/commitdiff
ICU-21764 icu-data-bin: fix filenames to nn_n
authorSteven R. Loomis <srl295@gmail.com>
Tue, 28 Sep 2021 21:18:11 +0000 (16:18 -0500)
committerPeter Edberg <42151464+pedberg-icu@users.noreply.github.com>
Wed, 29 Sep 2021 17:40:55 +0000 (10:40 -0700)
ex: icu4c-70_1-data-bin-b.zip
(was incorrectly "70.1" before)

icu4c/source/config/dist-data.sh

index 442267108baeb47cd7800403a8d3a079b43d5d1f..9406ebb3a6341e9c2ad88aff7ca1aabc47b7c031 100755 (executable)
@@ -27,8 +27,12 @@ then
     exit 1
 fi
 
+# Short (major) version, i.e. 70
 VERS=$(echo ${DATFILE} | tr -d a-z/.)
+# Version number, i.e. 70.1
 VERSION=${VERSION-unknown}
+# Version number for files, i.e. 70_1
+VERSION_FILE=$(echo ${VERSION} | tr . _)
 
 if [[ "${VERSION}" = "unknown" ]];
 then
@@ -57,7 +61,7 @@ mkdir -p ${DISTY_DIR}/tmp
 
 for endian in $ENDIANS;
 do
-    base=icu4c-${VERSION}-data-bin-${endian}.zip
+    base=icu4c-${VERSION_FILE}-data-bin-${endian}.zip
     filename=icudt${VERS}${endian}.dat
     if [ -f ${DISTY_DIR}/${base} ];
     then
@@ -67,7 +71,7 @@ do
     rm -f ${DISTY_DIR}/tmp/${filename}
     echo ./bin/icupkg -t${endian} ${DATFILE} ${DISTY_DIR}/tmp/${filename}
     ./bin/icupkg -t${endian} ${DATFILE} ${DISTY_DIR}/tmp/${filename}
-    README=icu4c-${VERSION}-data-bin-${endian}-README.md
+    README=icu4c-${VERSION_FILE}-data-bin-${endian}-README.md
     cat >> ${DISTY_DIR}/tmp/${README} <<EOF
 # ICU Data Zip for ${VERSION}