Skip to content

Commit 1926a16

Browse files
committed
templatize CollationTest.html
1 parent 51e7890 commit 1926a16

File tree

3 files changed

+17
-7
lines changed

3 files changed

+17
-7
lines changed

pub/copy-beta-to-draft.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ UNITOOLS_DATA=$UNICODETOOLS/unicodetools/data
1414
COPY_YEAR=2023
1515
UNI_VER=15.1.0
1616
EMOJI_VER=15.1
17+
# UTS #10 release revision number to be used in CollationTest.html:
18+
# One more than the last release revision number.
19+
TR10_REV=tr10-48
1720

1821
TODAY=`date --iso-8601`
1922

@@ -25,6 +28,7 @@ s/PUB_DATE/$TODAY/
2528
s/PUB_STATUS/draft/
2629
s/UNI_VER/$UNI_VER/
2730
s/EMOJI_VER/$EMOJI_VER/
31+
s/TR10_REV/$TR10_REV/
2832
s%PUBLIC_EMOJI%Public/draft/emoji/%
2933
s%PUBLIC_UCD_EMOJI%Public/draft/UCD/ucd/emoji/%
3034
eof
@@ -37,6 +41,7 @@ rm $DRAFT/UCD/ucd/zipped-ReadMe.txt
3741

3842
mkdir -p $DRAFT/UCA
3943
cp -r $UNITOOLS_DATA/uca/dev/* $DRAFT/UCA
44+
sed -i -f $DEST/sed-readmes.txt $DRAFT/UCA/CollationTest.html
4045

4146
mkdir -p $DRAFT/emoji
4247
cp $UNITOOLS_DATA/emoji/dev/* $DRAFT/emoji

pub/copy-final.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ UNITOOLS_DATA=$UNICODETOOLS/unicodetools/data
1414
COPY_YEAR=2023
1515
UNI_VER=15.1.0
1616
EMOJI_VER=15.1
17+
# UTS #10 release revision number to be used in CollationTest.html:
18+
# *Two* more than the last release revision number.
19+
TR10_REV=tr10-49
1720

1821
TODAY=`date --iso-8601`
1922

@@ -25,6 +28,7 @@ s/PUB_DATE/$TODAY/
2528
s/PUB_STATUS/final/
2629
s/UNI_VER/$UNI_VER/
2730
s/EMOJI_VER/$EMOJI_VER/
31+
s/TR10_REV/$TR10_REV/
2832
s%PUBLIC_EMOJI%Public/emoji/$EMOJI_VER/%
2933
s%PUBLIC_UCD_EMOJI%Public/$UNI_VER/ucd/emoji/%
3034
eof
@@ -38,6 +42,7 @@ mv $DEST/$UNI_VER/ucd/zipped-ReadMe.txt $DEST/zipped/$UNI_VER/ReadMe.txt
3842

3943
mkdir -p $DEST/UCA/$UNI_VER
4044
cp -r $UNITOOLS_DATA/uca/dev/* $DEST/UCA/$UNI_VER
45+
sed -i -f $DEST/sed-readmes.txt $DEST/UCA/$UNI_VER/CollationTest.html
4146

4247
mkdir -p $DEST/emoji/$EMOJI_VER
4348
cp $UNITOOLS_DATA/emoji/dev/* $DEST/emoji/$EMOJI_VER

unicodetools/data/uca/dev/CollationTest.html

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@
2222
</tbody></table>
2323
<div class="body">
2424
<h1>Unicode® Collation Algorithm<br>Conformance Tests</h1>
25-
<h2 align="center" class="changed">Version 15.1.0<br>2023-05-16</h2>
25+
<h2 align="center">Version UNI_VER<br>PUB_DATE</h2>
2626
<p>The following files provide conformance tests for the Unicode Collation Algorithm
27-
(<a href="https://www.unicode.org/reports/tr10/tr10-48.html">UTS #10: Unicode Collation Algorithm</a>).</p>
27+
(<a href="https://www.unicode.org/reports/tr10/TR10_REV.html">UTS #10: Unicode Collation Algorithm</a>).</p>
2828
<ul>
2929
<li>CollationTest_SHIFTED.txt</li>
3030
<li>CollationTest_NON_IGNORABLE.txt</li>
@@ -53,7 +53,7 @@ <h2>Format</h2>
5353
<p>There are four different files:</p>
5454
<ul>
5555
<li>The shifted vs non-ignorable files correspond to the two alternate
56-
<a href="https://www.unicode.org/reports/tr10/tr10-48.html#Variable_Weighting">Variable Weighting</a> values.</li>
56+
<a href="https://www.unicode.org/reports/tr10/TR10_REV.html#Variable_Weighting">Variable Weighting</a> values.</li>
5757
<li>The SHORT versions omit the comments, for more compact storage.</li>
5858
</ul>
5959
<p>The format is illustrated by the following example:</p>
@@ -75,7 +75,7 @@ <h2>Format</h2>
7575
<h2>Testing</h2>
7676
<p>The files are designed so each line in the file will order as being greater than or equal to
7777
the previous one, when using the UCA and the
78-
<a href="https://www.unicode.org/reports/tr10/tr10-48.html#Default_Unicode_Collation_Element_Table">Default
78+
<a href="https://www.unicode.org/reports/tr10/TR10_REV.html#Default_Unicode_Collation_Element_Table">Default
7979
Unicode Collation Element Table</a>.
8080
A test program can read in each line, compare it to
8181
the last line, and signal an error if order is not correct. The exact comparison that should be
@@ -123,17 +123,17 @@ <h3>Discontiguous contractions</h3>
123123
<li>S2.1.1 loops over each of the following three characters C,
124124
but there is no table entry for any of those three S+C.
125125
In particular, there is no DUCET mapping for 0FB2+0F71
126-
(see <i><a href="https://www.unicode.org/reports/tr10/tr10-48.html#Well_Formed_DUCET">Tibetan and
126+
(see <i><a href="https://www.unicode.org/reports/tr10/TR10_REV.html#Well_Formed_DUCET">Tibetan and
127127
Well-Formedness of DUCET</a></i>).</li>
128128
<li>The loop exits without finding any match beyond S=0FB2.</li>
129129
</ul>
130130

131131
<p>See “Also note that the Algorithm employs two distinct contraction matching methods:”
132132
at the end of <i>Section 7.2,
133-
<a href="https://www.unicode.org/reports/tr10/tr10-48.html#Step_2">Produce Collation Element Arrays</a></i>.</p>
133+
<a href="https://www.unicode.org/reports/tr10/TR10_REV.html#Step_2">Produce Collation Element Arrays</a></i>.</p>
134134

135135
<hr width="50%">
136-
<p class="copyright">© <span class="changed">2023</span> Unicode, Inc. All Rights Reserved.
136+
<p class="copyright">© COPY_YEAR Unicode, Inc. All Rights Reserved.
137137
The Unicode Consortium makes no expressed or implied warranty
138138
of any kind, and assumes no liability for errors or omissions. No liability
139139
is assumed for incidental and consequential damages in connection with or arising

0 commit comments

Comments
 (0)