Update build.yml #5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and Release SecVault | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
# Install JetBrains Runtime (JBR) | |
- name: Download JetBrains Runtime | |
run: | | |
JBR_VERSION=17.0.8-b520.12 # Replace with the desired version of JBR | |
JBR_URL="https://cache-redirector.jetbrains.com/intellij-jbr/jbrsdk-$JBR_VERSION-linux-x64-binaries.tar.gz" | |
wget $JBR_URL -O jbr.tar.gz | |
mkdir jbr | |
tar -xzf jbr.tar.gz -C jbr --strip-components=1 | |
# Set the JAVA_HOME to point to JetBrains Runtime | |
- name: Set up JetBrains Runtime | |
run: echo "JAVA_HOME=${{ github.workspace }}/jbr" >> $GITHUB_ENV | |
- name: Display current directory (for debugging) | |
run: pwd | |
- name: List files in current directory (for debugging) | |
run: ls -la | |
- name: Grant execution permissions for gradlew | |
run: chmod +x ./gradlew # Ensure gradlew is executable | |
- name: Build the app and force the MSI task to run | |
run: ./gradlew packageMsi --rerun-tasks --info # Force rerun of packageMsi task with info for debugging | |
- name: List output directories (for debugging) | |
run: ls -R build/compose/binaries # Verify that MSI files are created in expected directory | |
- name: Upload .msi artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: secvault-msi | |
path: build/compose/binaries/main/msi/*.msi # Ensure this matches the actual path after build | |
if-no-files-found: warn |