From a8fb526a638968464ade3d5e5e3595fe2430f410 Mon Sep 17 00:00:00 2001 From: tobiasKaminsky Date: Mon, 16 Mar 2026 10:05:09 +0100 Subject: [PATCH 1/2] QA APK on GitHub Signed-off-by: tobiasKaminsky --- .github/workflows/qa.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml index 770d09d9be25..18e1ca35b9c0 100644 --- a/.github/workflows/qa.yml +++ b/.github/workflows/qa.yml @@ -54,4 +54,11 @@ jobs: [ -e app/build.gradle.kts ] && sed -i "/qa/,/\}/ s/versionName .*/versionName = \"${{github.event.number}}\"/" "app/build.gradle.kts" ./gradlew assembleQaDebug $(find /usr/local/lib/android/sdk/build-tools/*/apksigner | sort | tail -n1) sign --ks-pass pass:"$KS_PASS" --key-pass pass:"$KEY_PASS" --ks-key-alias key0 --ks ".github/workflows/QA_keystore.jks" app/build/outputs/apk/qa/debug/*qa-debug*.apk - .github/workflows/uploadArtifact.sh "$LOG_USERNAME" "$LOG_PASSWORD" "${{github.event.number}}" "${{github.event.number}}" "$GITHUB_TOKEN" + + - name: Upload APK + uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f + with: + name: ${{github.event.number}}.zip + path: app/build/outputs/apk/qa/debug/*qa-debug*.apk + retention-days: 7 + archive: false From 16af2a24e7dd3c1d5b079def654e5527afc8c554 Mon Sep 17 00:00:00 2001 From: tobiasKaminsky Date: Mon, 16 Mar 2026 10:18:20 +0100 Subject: [PATCH 2/2] QA APK on GitHub Signed-off-by: tobiasKaminsky --- .github/workflows/qa.yml | 14 +++++++++++++- .github/workflows/uploadArtifact.sh | 6 +++--- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml index 18e1ca35b9c0..2fa310dd5b3f 100644 --- a/.github/workflows/qa.yml +++ b/.github/workflows/qa.yml @@ -56,9 +56,21 @@ jobs: $(find /usr/local/lib/android/sdk/build-tools/*/apksigner | sort | tail -n1) sign --ks-pass pass:"$KS_PASS" --key-pass pass:"$KEY_PASS" --ks-key-alias key0 --ks ".github/workflows/QA_keystore.jks" app/build/outputs/apk/qa/debug/*qa-debug*.apk - name: Upload APK + id: upload-apk uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f with: - name: ${{github.event.number}}.zip path: app/build/outputs/apk/qa/debug/*qa-debug*.apk retention-days: 7 archive: false + + - name: Create QR Code + uses: roshangm1/qr-code-commenter-action@ef11477a76fa017e4f70b4dd7c56694c985099ce + with: + repo-token: "${{ secrets.GITHUB_TOKEN }}" + content: "${{ steps.upload-apk.outputs.artifact-url }}" + comment: | + APK file: ${{ steps.upload-apk.outputs.artifact-url }} + To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app. + {qrcode} + + diff --git a/.github/workflows/uploadArtifact.sh b/.github/workflows/uploadArtifact.sh index bf96572045ab..69f203bbf5c4 100755 --- a/.github/workflows/uploadArtifact.sh +++ b/.github/workflows/uploadArtifact.sh @@ -18,6 +18,7 @@ PASS=$2 BUILD=$3 PR=$4 GITHUB_TOKEN=$5 +URL=$6 DAV_URL=https://nextcloud.kaminsky.me/remote.php/dav/files/$USER/android-artifacts/ source .github/workflows/lib.sh @@ -26,7 +27,7 @@ REPO=$(cat scripts/repo) if ! test -e app/build/outputs/apk/qa/debug/*qa-debug*.apk ; then exit 1 fi -echo "Uploaded artifact to $DAV_URL/$BUILD.apk" +echo "Uploaded artifact to $URL" # delete all old comments, starting with "APK file:" oldComments=$(curl_gh -X GET https://api.github.com/repos/nextcloud/$REPO/issues/$PR/comments | jq '.[] | (.id |tostring) + "|" + (.user.login | test("github-actions") | tostring) + "|" + (.body | test("APK file:.*") | tostring)' | grep "true|true" | tr -d "\"" | cut -f1 -d"|") @@ -37,8 +38,7 @@ done sudo apt-get -y install qrencode -qrencode -o $PR.png "$PUBLIC_URL/$BUILD.apk" +qrencode -o $PR.png "$URL" -curl -u $USER:$PASS -X PUT $DAV_URL/$BUILD.apk --upload-file app/build/outputs/apk/qa/debug/*qa-debug*.apk curl -u $USER:$PASS -X PUT $DAV_URL/$BUILD.png --upload-file $PR.png curl_gh -X POST https://api.github.com/repos/nextcloud/$REPO/issues/$PR/comments -d "{ \"body\" : \"APK file: $PUBLIC_URL/$BUILD.apk

![qrcode]($PUBLIC_URL/$BUILD.png)

To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app. \" }"