Skip to content

Commit

Permalink
correct build scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
infeo committed Nov 18, 2024
1 parent 2060729 commit ded3f90
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/build-binary.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ on:
description: 'Version'
required: false

permissions:
contents: write
packages: write

env:
JAVA_DIST: 'zulu'
JAVA_VERSION: '22.0.2+9'
Expand Down Expand Up @@ -78,7 +82,7 @@ jobs:
- uses: actions/setup-java@v4
with:
java-version: '22'
distribution: 'temurin'
distribution: 'zulu'
- name: Set version
run: mvn versions:set -DnewVersion=${{ needs.prepare.outputs.semVerStr }}
- name: Run maven
Expand Down Expand Up @@ -124,7 +128,7 @@ jobs:
${JPACKAGE_OS_OPTS}
- uses: actions/upload-artifact@v4
with:
path: .\target\cryptomator-cli${{ matrix.binary-dir-suffix }}
path: ./target/cryptomator-cli${{ matrix.binary-dir-suffix }}
if-no-files-found: error
- name: Zip binary for release
if: startsWith(github.ref, 'refs/tags/') && github.event.action == 'published'
Expand All @@ -133,7 +137,7 @@ jobs:
- name: Create detached GPG signature with key 615D449FE6E6A235
run: |
echo "${GPG_PRIVATE_KEY}" | gpg --batch --quiet --import
echo "${GPG_PASSPHRASE}" | gpg --batch --quiet --passphrase-fd 0 --pinentry-mode loopback -u 615D449FE6E6A235 --detach-sign -a .\cryptomator-cli-${{ needs.prepare.outputs.semVerStr }}.zip
echo "${GPG_PASSPHRASE}" | gpg --batch --quiet --passphrase-fd 0 --pinentry-mode loopback -u 615D449FE6E6A235 --detach-sign -a ./cryptomator-cli-${{ needs.prepare.outputs.semVerStr }}.zip
env:
GPG_PRIVATE_KEY: ${{ secrets.RELEASES_GPG_PRIVATE_KEY }}
GPG_PASSPHRASE: ${{ secrets.RELEASES_GPG_PASSPHRASE }}
Expand Down
2 changes: 1 addition & 1 deletion build_linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ if [ -z "$JAVA_HOME" ]; then
fi

# Check Java version
MIN_JAVA_VERSION=$(mvn help:evaluate "-Dexpression=jdk.version" -q -DforceStdout):w
MIN_JAVA_VERSION=$(mvn help:evaluate "-Dexpression=jdk.version" -q -DforceStdout)
JAVA_VERSION=$("$JAVA_HOME/bin/java" -version | head -n1 | cut -d' ' -f2 | cut -d'.' -f1)
if [ "$JAVA_VERSION" -lt "$MIN_JAVA_VERSION" ]; then
echo "Java version $JAVA_VERSION is too old. Minimum required version is $MIN_JAVA_VERSION"
Expand Down

0 comments on commit ded3f90

Please sign in to comment.