File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -37,12 +37,17 @@ jobs:
3737 - name : Build Java JAR
3838 run : ./gradlew clean build
3939
40+ - name : Get Gradle version
41+ id : gradle_version
42+ run : |
43+ echo "VERSION=$(./gradlew -q printVersion)" >> $GITHUB_ENV
44+
4045 - name : Prepare release-artifacts folder
4146 shell : pwsh
4247 run : |
4348 New-Item -ItemType Directory -Path "release-artifacts" -Force
4449 Copy-Item -Path "src/main/resources/native/SMTC4J.dll" -Destination "release-artifacts/SMTC4J.dll" -Force
45- Copy-Item -Path "build/libs/SMTC4J-${GITHUB_REF_NAME} .jar" -Destination "release-artifacts/SMTC4J.jar" -Force
50+ Copy-Item -Path "build/libs/SMTC4J-$env:VERSION .jar" -Destination "release-artifacts/SMTC4J-$env:VERSION .jar" -Force
4651
4752 - name : List release artifacts
4853 run : dir release-artifacts
Original file line number Diff line number Diff line change @@ -19,6 +19,12 @@ java {
1919 }
2020}
2121
22+ tasks. register(' printVersion' ) {
23+ doLast {
24+ println project. version
25+ }
26+ }
27+
2228def nativeDownloadDir = layout. buildDirectory. dir(" native-download" ). get(). asFile
2329def downloadedNativeDllFile = nativeDownloadDir. toPath(). resolve(" SMTC4J.dll" ). toFile()
2430def resourcesNativeDir = layout. buildDirectory. dir(" resources/main/native" ). get(). asFile
You can’t perform that action at this time.
0 commit comments