Skip to content

Commit 6e7404c

Browse files
author
OpenCode Bot
committed
fix: fix JAVA_HOME path in workflow
1 parent d139204 commit 6e7404c

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

.github/workflows/build.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,13 @@ jobs:
3838
- name: Grant execute permission
3939
run: chmod +x gradlew
4040

41+
- name: Find Java
42+
run: |
43+
echo "JAVA_HOME=$(dirname $(dirname $(which java)))" >> $GITHUB_ENV
44+
echo "PATH=$(dirname $(which java)):$PATH" >> $GITHUB_ENV
45+
4146
- name: Build Release APK
4247
run: ./gradlew assembleRelease --no-daemon 2>&1
43-
env:
44-
JAVA_HOME: /opt/hostedtoolcache/Java_Temurin-Hotspot_jdk/17.0.9*/x64
4548

4649
- name: Upload APK
4750
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')

0 commit comments

Comments
 (0)