From 7f1cefc134a483d0652f4cf8c7b2ea216601712b Mon Sep 17 00:00:00 2001 From: paytoncain Date: Tue, 23 Apr 2024 14:09:52 -0600 Subject: [PATCH] Update workflow --- .github/workflows/maven.yml | 44 +++++++++++++++++++++++++++++++++++-- 1 file changed, 42 insertions(+), 2 deletions(-) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index a9fefd61..e2b9d9f6 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -67,13 +67,12 @@ jobs: -i jars --main-class edu.colorado.cire.pace.cli.Application --main-jar pace-cli-${{ needs.build.outputs.version }}-jar-with-dependencies.jar - - name: View artifacts - run: ls -l - name: Upload app image uses: actions/upload-artifact@v4 with: name: pace-cli-${{ env.os }}-${{ env.arch }} path: "*.app" + package-linux: needs: build strategy: @@ -110,10 +109,50 @@ jobs: with: name: pace-cli-${{ env.os }}-${{ env.arch }} path: "pace-cli" + + package-windows: + needs: build + strategy: + matrix: + os: [ windows-2019 ] + runs-on: ${{ matrix.os }} + steps: + - name: Set up JDK 17 + uses: actions/setup-java@v4 + with: + java-version: '17' + distribution: 'temurin' + - name: Set os/arch environment variables + run: | + echo "os=${RUNNER_OS}" >> $GITHUB_ENV + echo "arch=${RUNNER_ARCH}" >> $GITHUB_ENV + - name: Download Jar + uses: actions/download-artifact@v4 + with: + name: jar-with-dependencies + path: jars + - name: Package jar as app-image + run: > + jpackage + --type app-image + --verbose + --vendor 'CIRES - University of Colorado' + --name 'pace-cli' + -i jars + --dest application + --main-class edu.colorado.cire.pace.cli.Application + --main-jar pace-cli-${{ needs.build.outputs.version }}-jar-with-dependencies.jar + - name: Upload app image + uses: actions/upload-artifact@v4 + with: + name: pace-cli-${{ env.os }}-${{ env.arch }} + path: application release: needs: - package-osx + - package-linux + - package-windows runs-on: ubuntu-latest steps: - uses: actions/download-artifact@v4 @@ -121,6 +160,7 @@ jobs: - run: zip -r release/pace-cli-Linux-X64-${{ needs.build.outputs.version }}.zip pace-cli-Linux-X64 - run: zip -r release/pace-cli-macOS-ARM64-${{ needs.build.outputs.version }}.zip pace-cli-macOS-ARM64 - run: zip -r release/pace-cli-macOS-X64-${{ needs.build.outputs.version }}.zip pace-cli-macOS-X64 + - run: zip -r release/pace-cli-Windows-X64-${{ needs.build.outputs.version }}.zip pace-cli-Windows-X64 - name: Update branch release uses: eine/tip@master with: