diff --git a/.github/workflows/build-artifacts.yml b/.github/workflows/build-artifacts.yml index 2e41d324..5e9643f7 100644 --- a/.github/workflows/build-artifacts.yml +++ b/.github/workflows/build-artifacts.yml @@ -371,6 +371,8 @@ jobs: matrix: os: [ windows-2019 ] runs-on: ${{ matrix.os }} + outputs: + appver: ${{ steps.appver.outputs.appver }} steps: - name: Set up JDK 17 uses: actions/setup-java@v4 @@ -391,16 +393,34 @@ jobs: with: name: gui-icons path: icons - - name: Package jar as exe application + - id: appver run: | - appver=$(date +%y.%m.%d%H) - jpackage --verbose --dest application --name "pace" -i jars --main-class edu.colorado.cires.pace.gui.Application --main-jar pace-gui-${{ needs.build.outputs.version }}.jar -t exe --icon icons/pace.ico --vendor "CIRES - University of Colorado" --win-shortcut --win-menu --win-dir-chooser --win-per-user-install --app-version $appver + echo "appver=$(date +%y.%m.%d%H)" >> $GITHUB_OUTPUT + echo "appver=$(date +%y.%m.%d%H)" >> $GITHUB_ENV shell: bash + - name: Package jar as exe application + run: > + jpackage + --verbose + --dest application + --name "pace" + -i jars + --main-class edu.colorado.cires.pace.gui.Application + --main-jar + pace-gui-${{ needs.build.outputs.version }}.jar + -t exe + --icon icons/pace.ico + --vendor "CIRES - University of Colorado" + --win-shortcut + --win-menu + --win-dir-chooser + --win-per-user-install + --app-version ${{ env.appver }} - name: Upload application uses: actions/upload-artifact@v4 with: name: pace-gui-${{ env.os }}-${{ env.arch }} - path: application + path: "application/*.exe" release: needs: @@ -410,7 +430,7 @@ jobs: steps: - uses: actions/download-artifact@v4 - run: mkdir release - - run: zip -r release/pace-gui-Windows-X64-${{ needs.build.outputs.version }}.zip pace-gui-Windows-X64 + - run: cp pace-gui-Windows-X64/pace-${{ needs.package-gui-windows.outputs.appver }}.exe release/pace-gui-Windows-X64-${{ needs.build.outputs.version }}.exe - run: cp cli-jar/* release/pace-cli-${{ needs.build.outputs.version }}-exe.jar - run: cp gui-jar/* release/pace-gui-${{ needs.build.outputs.version }}-exe.jar - run: zip -r release/pace-json-schema-${{ needs.build.outputs.version }}.zip json-schema