Skip to content

Commit

Permalink
Merge pull request #21366 from Expensify/Rory-ReleasePendingIOSApps
Browse files Browse the repository at this point in the history
[No QA] Release pending versions before submitting a new version for review
  • Loading branch information
AndrewGable authored Jun 28, 2023
2 parents ecfcd83 + cddb103 commit d1a743c
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions fastlane/Fastfile
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,26 @@ platform :ios do

desc "Move app to App Store Review"
lane :production do
# Login to Spaceship
fastlane_require 'spaceship'
teamID = CredentialsManager::AppfileConfig.try_fetch_value(:team_id)
Spaceship::ConnectAPI.login(
use_portal: false,
tunes_team_id: teamID,
)

# Find our app
bundleID = CredentialsManager::AppfileConfig.try_fetch_value(:app_identifier)
app = Spaceship::ConnectAPI::App.find(bundleID)
if app.nil?
UI.important "not found in team #{teamID} on ASC!"
next
else
# If there's an app that's Pending Developer Release, release it before continuing with the new version
pendingReviewVersion = app.get_pending_release_app_store_version
version.create_app_store_version_release_request unless version.nil?
end

deliver(
api_key_path: "./ios/ios-fastlane-json-key.json",

Expand Down

0 comments on commit d1a743c

Please sign in to comment.