Skip to content

Commit f692cc3

Browse files
committedOct 18, 2022
fix(build): use cldr.version for cldr
- github action should use the cldr.version for checkout Fixes #316
1 parent 0758116 commit f692cc3

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed
 

‎.github/workflows/build-jsp.yml

+12-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
name: Build JSP
22

3+
env:
4+
CURRENT_UVERSION: 15.1.0
5+
PREVIOUS_UVERSION: 15.0.0 # not used at present
6+
37
on:
48
push:
59
branches:
@@ -11,12 +15,16 @@ jobs:
1115
build:
1216
runs-on: ubuntu-latest
1317
steps:
14-
- uses: actions/checkout@v2
18+
- uses: actions/checkout@v3
19+
- name: Get the CLDR_REF from pom.xml
20+
id: cldr_ref
21+
run: pip install yq && echo ::set-output name=CLDR_REF::$(xq -r '.project.properties["cldr.version"]' < pom.xml)
1522
- name: Check out CLDR
1623
uses: actions/checkout@v2
1724
with:
1825
repository: unicode-org/cldr
1926
path: cldr
27+
ref: ${{ steps.cldr-ref.outputs.CLDR_REF}}
2028
- name: Backup Unicodetools and CLDR for jsps # this is needed only for the Docker build
2129
run:
2230
mkdir -p UnicodeJsps/target && tar cfpz UnicodeJsps/target/cldr-unicodetools.tgz ./cldr ./unicodetools
@@ -38,16 +46,16 @@ jobs:
3846
run: >
3947
mkdir -pv $(pwd)/output/Generated/ &&
4048
mvn -s .github/workflows/mvn-settings.xml -B compile exec:java -DskipTests=true
41-
-Dexec.mainClass="org.unicode.text.UCD.Main" -Dexec.args="version 15.1.0 build MakeUnicodeFiles"
49+
-Dexec.mainClass="org.unicode.text.UCD.Main" -Dexec.args="version ${CURRENT_UVERSION} build MakeUnicodeFiles"
4250
-am -pl unicodetools -DCLDR_DIR=${GITHUB_WORKSPACE}/cldr
43-
-DUNICODETOOLS_REPO_DIR=$(pwd) -DUVERSION=15.1.0
51+
-DUNICODETOOLS_REPO_DIR=$(pwd) -DUVERSION=${CURRENT_UVERSION}
4452
-DUNICODETOOLS_GEN_DIR=$(pwd)/output/Generated
4553
env:
4654
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4755
- name: Run unicodetools tests
4856
run: >
4957
mvn -s .github/workflows/mvn-settings.xml -B test -am -pl unicodetools
50-
-DCLDR_DIR=${GITHUB_WORKSPACE}/cldr -T 1C -Dparallel=classes -DUNICODETOOLS_REPO_DIR=$(pwd) -DUVERSION=15.1.0 -DUNICODETOOLS_GEN_DIR=$(pwd)/output/Generated
58+
-DCLDR_DIR=${GITHUB_WORKSPACE}/cldr -T 1C -Dparallel=classes -DUNICODETOOLS_REPO_DIR=$(pwd) -DUVERSION=${CURRENT_UVERSION} -DUNICODETOOLS_GEN_DIR=$(pwd)/output/Generated
5159
env:
5260
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5361
- name: Package JSPs

0 commit comments

Comments
 (0)
Failed to load comments.