use correct pwsh syntax on all publish workflows

This commit is contained in:
Armin Schrenk 2022-12-05 16:49:19 +01:00
parent d6e14dab9a
commit b2b49f4d2f
No known key found for this signature in database
GPG Key ID: 8F2992163CBBA7FC
4 changed files with 15 additions and 15 deletions

View File

@ -36,7 +36,7 @@ jobs:
run: |
$jfxPomVersion = (&mvn help:evaluate "-Dexpression=javafx.version" -q -DforceStdout) -split "\."
$jfxJdkVersion = ((Get-Content -path "${env:JAVA_HOME}/lib/javafx.properties" | Where-Object {$_ -like 'javafx.version=*' }) -replace '.*=','') -split "\."
if ($jfxPomVersion[0] -ne $jfxJdkVersion) {
if ($jfxPomVersion[0] -ne $jfxJdkVersion[0]) {
Write-Error "Major part of JavaFX version in pom($($jfxPomVersion[0])) does not match the version in JDK($($jfxJdkVersion[0])) "
exit 1
}

View File

@ -64,15 +64,15 @@ jobs:
- name: Ensure major jfx version in pom and in jmods is the same
shell: pwsh
run: |
$jfxPomVersion = (&mvn help:evaluate -Dexpression=javafx.version -q -DforceStdout) -split "\."
$jfxJmodVersionAmd64 = (Get-Content -Path "jmods/aarch64/javafx.properties" | Where-Object {$_ -like 'javafx.version=*' }) -replace '.*=',''
$jfxJmodVersionAarch64 = (Get-Content -Path "jmods/aarch64/javafx.properties" | Where-Object {$_ -like 'javafx.version=*' }) -replace '.*=',''
if ($jfxJmodVersionAmd64 -ne $jfxJmodVersionAarch64 ) {
$jfxPomVersion = (&mvn help:evaluate "-Dexpression=javafx.version" -q -DforceStdout) -split "\."
$jfxJmodVersionAmd64 = ((Get-Content -Path "jmods/aarch64/javafx.properties" | Where-Object {$_ -like 'javafx.version=*' }) -replace '.*=','') -split "\."
$jfxJmodVersionAarch64 = ((Get-Content -Path "jmods/aarch64/javafx.properties" | Where-Object {$_ -like 'javafx.version=*' }) -replace '.*=','') -split "\."
if ($jfxJmodVersionAmd64[0] -ne $jfxJmodVersionAarch64[0] ) {
Write-Error "JavaFX Jmods for aarch64 and amd64 are different major versions"
exit 1
}
if ($jfxPomVersion[0] -ne $jfxJmodVersionAmd64) {
Out-Error "Major part of JavaFX version in pom($($jfxPomVersion[0])) does not match the version of Jmods(${jfxJmodVersion}) "
if ($jfxPomVersion[0] -ne $jfxJmodVersionAmd64[0]) {
Out-Error "Major part of JavaFX version in pom($($jfxPomVersion[0])) does not match the version of Jmods($($jfxJmodVersionAmd64[0])) "
exit 1
}
- name: Create orig.tar.gz with common/ libs/ mods/ jmods/

View File

@ -47,10 +47,10 @@ jobs:
- name: Ensure major jfx version in pom equals in jdk
shell: pwsh
run: |
$jfxPomVersion = (&mvn help:evaluate -Dexpression=javafx.version -q -DforceStdout) -split "\."
$jfxJdkVersion = (Get-Content -path "${env:JAVA_HOME}/lib/javafx.properties" | Where-Object {$_ -like 'javafx.version=*' }) -replace '.*=',''
if ($jfxPomVersion[0] -ne $jfxJdkVersion) {
Write-Error "Major part of JavaFX version in pom($($jfxPomVersion[0])) does not match the version in JDK(${jfxJdkVersion}) "
$jfxPomVersion = (&mvn help:evaluate "-Dexpression=javafx.version" -q -DforceStdout) -split "\."
$jfxJdkVersion = ((Get-Content -path "${env:JAVA_HOME}/lib/javafx.properties" | Where-Object {$_ -like 'javafx.version=*' }) -replace '.*=','') -split "\."
if ($jfxPomVersion[0] -ne $jfxJdkVersion[0]) {
Write-Error "Major part of JavaFX version in pom($($jfxPomVersion[0])) does not match the version in JDK($($jfxJdkVersion[0])) "
exit 1
}
- name: Set version

View File

@ -42,10 +42,10 @@ jobs:
- name: Ensure major jfx version in pom equals in jdk
shell: pwsh
run: |
$jfxPomVersion = (&mvn help:evaluate -Dexpression=javafx.version -q -DforceStdout) -split "\."
$jfxJdkVersion = (Get-Content -path "${env:JAVA_HOME}/lib/javafx.properties" | Where-Object {$_ -like 'javafx.version=*' }) -replace '.*=',''
if ($jfxPomVersion[0] -ne $jfxJdkVersion) {
Write-Error "Major part of JavaFX version in pom($($jfxPomVersion[0])) does not match the version in JDK(${jfxJdkVersion}) "
$jfxPomVersion = (&mvn help:evaluate "-Dexpression=javafx.version" -q -DforceStdout) -split "\."
$jfxJdkVersion = ((Get-Content -path "${env:JAVA_HOME}/lib/javafx.properties" | Where-Object {$_ -like 'javafx.version=*' }) -replace '.*=','') -split "\."
if ($jfxPomVersion[0] -ne $jfxJdkVersion[0]) {
Write-Error "Major part of JavaFX version in pom($($jfxPomVersion[0])) does not match the version in JDK($($jfxJdkVersion[0])) "
exit 1
}
- name: Set version