File tree Expand file tree Collapse file tree 2 files changed +27
-0
lines changed
actions/get-supported-jdks Expand file tree Collapse file tree 2 files changed +27
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Get supported JDKs
2
+ description : Get supported JDKs
3
+ inputs :
4
+ HZ_VERSION :
5
+ description : HZ Version
6
+ required : true
7
+ outputs :
8
+ jdks :
9
+ value : ${{ steps.get-supported-jdks.outputs.jdks }}
10
+ description : Returns supported JDKs
11
+ runs :
12
+ using : " composite"
13
+ steps :
14
+ - shell : bash
15
+ id : get-supported-jdks
16
+ run : |
17
+ . .github/scripts/version.functions.sh
18
+ HZ_VERSION="${{ inputs.HZ_VERSION }}"
19
+ if version_less_than "$HZ_VERSION" "5.4.0"; then
20
+ echo "jdks=['11', '17']" >> $GITHUB_OUTPUT
21
+ else
22
+ echo "jdks=['17', '21']" >> $GITHUB_OUTPUT
23
+ fi
Original file line number Diff line number Diff line change @@ -28,6 +28,10 @@ function version_less_or_equal() {
28
28
[ " $1 " = " $( echo -e " $1 \n$2 " | sort -V | head -n1) " ]
29
29
}
30
30
31
+ function version_less_than() {
32
+ [ " $1 " != " $2 " ] && version_less_or_equal " $1 " " $2 "
33
+ }
34
+
31
35
function get_tags_descending() {
32
36
git tag -l " v*" | sort -V -r | grep -v ' -'
33
37
}
You can’t perform that action at this time.
0 commit comments