Skip to content

Commit dcbf502

Browse files
fix: address runtime crash risks found during review
Agent-Logs-Url: https://github.com/winnerspiros/osu/sessions/df8487e1-1028-44d9-adc9-42e5e885e5a3 Co-authored-by: winnerspiros <1675249+winnerspiros@users.noreply.github.com>
1 parent 282a1f6 commit dcbf502

2 files changed

Lines changed: 12 additions & 9 deletions

File tree

.github/workflows/generate-keystore.yml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,12 @@ jobs:
2222
generate:
2323
name: Generate Keystore
2424
runs-on: ubuntu-latest
25+
permissions: {}
2526
steps:
27+
# Mask the password so it is never printed in logs.
28+
- name: Mask password
29+
run: echo "::add-mask::${{ inputs.key_password }}"
30+
2631
- name: Validate inputs
2732
run: |
2833
if [ ${#KEY_PASSWORD} -lt 6 ]; then
@@ -54,7 +59,6 @@ jobs:
5459
id: encode
5560
run: |
5661
B64=$(base64 -w 0 osu-release.keystore)
57-
# Write to a file for the summary (avoid exposing in logs)
5862
echo "$B64" > keystore-base64.txt
5963
echo "encoded=true" >> "$GITHUB_OUTPUT"
6064
@@ -96,9 +100,12 @@ jobs:
96100
echo " 4. ANDROID_SIGNING_STORE_PASSWORD"
97101
echo " → Value: the password you entered when triggering this workflow"
98102
echo ""
99-
echo " IMPORTANT: Keep a backup of the keystore file! If you lose it,"
100-
echo " you will never be able to update your installed APK — you would"
101-
echo " have to uninstall and reinstall (losing all local data)."
103+
echo " IMPORTANT:"
104+
echo " • Keep a backup of the keystore file! If you lose it, you will"
105+
echo " never be able to update your installed APK — you would have to"
106+
echo " uninstall and reinstall (losing all local data)."
107+
echo " • After saving the secrets, DELETE this workflow run to remove"
108+
echo " the keystore artifact (Settings → Actions → this run → Delete)."
102109
echo ""
103110
echo " After saving the secrets, run the 'Build Android APK' workflow."
104111
echo "==================================================================="

.github/workflows/release.yml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -146,13 +146,9 @@ jobs:
146146
if [ -z "$APK" ]; then
147147
APK=$(find "osu.Android/bin/Release" -name "*-Signed.apk" | head -1)
148148
fi
149-
if [ -z "$APK" ]; then
150-
# Fall back to any APK if -Signed variant isn't produced
151-
APK=$(find "osu.Android/bin/Release/net10.0-android/publish" -maxdepth 1 -name "*.apk" 2>/dev/null | head -1)
152-
fi
153149
154150
if [ -z "$APK" ]; then
155-
echo "::error::Failed to locate APK. Listing bin directory:"
151+
echo "::error::Failed to locate signed APK. Listing bin directory:"
156152
find osu.Android/bin -name "*.apk" -o -name "*.aab" 2>/dev/null || true
157153
exit 1
158154
fi

0 commit comments

Comments
 (0)