Bugfix: App Store and Testflight latest build numbers #300
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changes in this pull request fix the actions that detect the latest build number from App Store Connect for App Store or Pre Release (TestFlight) versions:
app-store-connect get-latest-testflight-build-number
,app-store-connect get-latest-app-store-build-number
andapp-store-connect get-latest-build-number
.In previous versions if
--pre-release-version
or--app-store-version
argument was omitted, then the global latest version for an app was detected only based on build versions, which can lead to wrong results. For example consider the case where we have1.0.1
with builds1
,2
,3
and1.0.0
with builds1
,2
, ...,5
,6
.0.0.1
with builds ...,5
,999
.In this case the expected latest build is from TestFlight version
1.0.1
with version number3
. But the previous versions pick build with number999
from TestFlight version0.0.1
since TestFlight versions were omitted from comparison entirely. Similar issue applies to App Store versions and their build.Another minor change is that now the detected build number and TestFlight / App Store versions are logged out to STDERR stream. This is useful as the most common use-case for these actions is to capture the current latest build number into a shell variable, which can then be used to set the version of next build.
Example
Old version:
Updated version:
Updated actions:
app-store-connect get-latest-testflight-build-number
app-store-connect get-latest-app-store-build-number
app-store-connect get-latest-build-number