-
Notifications
You must be signed in to change notification settings - Fork 224
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft: Android CI production build and Play Store auto-submission #2909
Conversation
Hi @danryu, Thanks for your PR. Could you review the check failures and fix them, please. -- Peter |
Pushed all the fixes that I could see needed handling. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you very much
Jamulus.pro
Outdated
ANDROID_VERSION_CODE = $$system(git log --oneline | wc -l) | ||
|
||
# date-based unique value - prevent clashes in Play Store build numbering | ||
!defined(ANDROID_VERSION_CODE, var):ANDROID_VERSION_CODE = $$system(date +%s | cut -c 2-) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will not work on windows I suppose? Wouldn't the git commit hash or something else be better?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The CI is obviously targeted purely for Linux.
For local building on Windows we can just hardcode any int value.
ANDROID_VERSION_CODE = 123456
Android Version Code requires an integer <=2100000000.
So you'd need some custom logic to convert the shorthash to int first.
I don't like relying on git log because you need a separate version code for armeabi7 and armv8 builds.
The above date
output guarantees a unique, valid value for each Play Store submission.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The CI is obviously targeted purely for Linux.
But as it's in Jamulus.pro we should ensure cross compatibility. Even if it's a noop.
If the additional Github Secrets are added according to the updated Documentation section in this PR, the Auto-Build should complete successfully. There are some Coding Style failures and I'm not sure how valid or useful the remaining shfmt errors are - unfortunately I don't have more time to devote to this PR. If desired, you can merge the changes to a future feature branch and I can close this PR. |
Ok. Squashed and merged to a feature branch: https://github.com/jamulussoftware/jamulus/tree/feature/koord/CIPlaystore. Hopefully, in future work can be continued. Closing. |
@danryu Thanks a lot of upstreaming this! I think this PR contains some very valuable contributions to update the build environment and enable Qt6 compatibility (#2528). Not sure if we should integrate the playstore-related parts right now, might still be a bit early with little to no testing happening in this area. Sorry for not chiming in earlier (time is limited...). I certainly plan to integrate large parts of this and will submit new PR(s) with the relevant parts (with proper attribution of @danryu, of course). |
@hoffie Happy to contribute! PS if you want to get a sense of the end result of this PR, a reasonable indicator is to try Koord, as installed from the Play Store. Edit: Note that this PR doesn't push the build straight to Live/Production status. The default is to go to an Open Testing track for beta testers only, and is in draft status until you promote it in the Play Store GUI. |
For clarity, we're looking at splitting this into:
Currently "in progress" is #2528. |
I think a lot of work is already done on the feature branch. I'd personally focus on iOS as I don't own an up to date Android device. |
Description
This PR implements a best-practices CI build for submission of the client to Google Play Store, following the advice at
https://doc.qt.io/qt-6/android-publishing-to-googleplay.html
This includes additional small changes for recording permission with Qt6 on Android, and does not support Qt5.
Note: I have found from experience that it is better to use the Github-image-provided Android SDK/NDK tools, rather than create custom logic to do custom installations of those. See the notes in
android.sh
.This build creates 4 x separate .aab files (one for each available Android ABI) and submits them as part of the same package to the Play Store, where the developer can then add it to a Testing track as they please.
Note that this PR doesn't push the build straight to Live/Production status. The default is to go to an Open Testing track for beta testers only, and is in draft status until you promote it in the Play Store GUI.
CHANGELOG: Build Android release for Play Store and auto-submit
Documentation
Requires additional GITHUB SECRETS:
${{ secrets.GOOGLE_SERVICE_ACCOUNT_JSON }}
${{ secrets.GOOGLE_KEYSTORE }}
${{ secrets.GOOGLE_KEYSTORE_PASS }}
Status of this Pull Request
What is missing until this pull request can be merged?
Checklist