9292 - name : Build Android APK (signed)
9393 if : steps.keystore.outputs.has_keystore == 'true'
9494 run : >
95- dotnet publish -c Release -p:AndroidKeyStore=false -p:PublishTrimmed=false -p:AndroidLinkMode=None
95+ dotnet publish -c Release
9696 osu.Android/osu.Android.csproj
9797 -f net10.0-android
9898 -p:Version=${{ steps.version.outputs.version }}
@@ -104,24 +104,33 @@ jobs:
104104 -p:AndroidSigningKeyPass=${{ secrets.ANDROID_SIGNING_KEY_PASSWORD }}
105105 -p:AndroidSigningStorePass=${{ secrets.ANDROID_SIGNING_STORE_PASSWORD }}
106106
107- - name : Build Android APK (signed with default debug key )
107+ - name : Build Android APK (unsigned )
108108 if : steps.keystore.outputs.has_keystore != 'true'
109109 run : >
110- dotnet publish -c Release -p:AndroidKeyStore=false -p:PublishTrimmed=false -p:AndroidLinkMode=None
110+ dotnet publish -c Release
111111 osu.Android/osu.Android.csproj
112112 -f net10.0-android
113113 -p:Version=${{ steps.version.outputs.version }}
114114 -p:ApplicationDisplayVersion=${{ steps.version.outputs.version }}
115115 -p:ApplicationVersion=${{ github.run_number }}
116+ -p:AndroidKeyStore=false
116117
117118 - name : Find APK
118119 id : find_apk
119120 run : |
120- PUBLISH_DIR="osu.Android/bin/Release/net10.0-android"
121+ # The signed/final APK is inside the publish/ directory in net10.0-android
122+ PUBLISH_DIR="osu.Android/bin/Release/net10.0-android/publish"
121123 APK=$(find "$PUBLISH_DIR" -maxdepth 1 -name "*.apk" 2>/dev/null | head -1)
122124 if [ -z "$APK" ]; then
125+ # Fallback to the parent directory if publish/ doesn't exist for some reason
126+ PUBLISH_DIR="osu.Android/bin/Release/net10.0-android"
127+ APK=$(find "$PUBLISH_DIR" -maxdepth 1 -name "*.apk" 2>/dev/null | head -1)
128+ fi
129+ if [ -z "$APK" ]; then
130+ # Last resort: recursive find
123131 APK=$(find osu.Android/bin/Release -name "*.apk" | head -1)
124132 fi
133+ echo "Found APK at: $APK"
125134 echo "apk_path=$APK" >> "$GITHUB_OUTPUT"
126135
127136 - name : Upload APK artifact
0 commit comments