diff --git a/fastlane/Fastfile b/fastlane/Fastfile index 3e8725d..a493d7a 100644 --- a/fastlane/Fastfile +++ b/fastlane/Fastfile @@ -112,12 +112,17 @@ platform :ios do "sort" => "-createdDate" }) rows = resp.body["data"] || [] + # Resolve build ids so each report says which build it came from. + builds = {} + (resp.body["included"] || []).each do |inc| + builds[inc["id"]] = inc.dig("attributes", "version") if inc["type"] == "builds" + end UI.important("none") if rows.empty? rows.each do |row| a = row["attributes"] || {} - UI.message("── #{a['createdDate']} — #{a['deviceModel']} — #{a['osVersion']} — id #{row['id']}") + build = builds[row.dig("relationships", "build", "data", "id")] + UI.message("── #{a['createdDate']} — build #{build || '?'} — #{a['deviceModel']} — #{a['osVersion']} — id #{row['id']}") UI.message(" #{a['comment']}") if a["comment"] - UI.message(" crashLog: #{a['crashLog'] || row.dig('relationships', 'crashLog', 'links', 'related')}") end rescue => e UI.error("#{path}: #{e.message[0, 200]}") @@ -145,6 +150,11 @@ platform :ios do app.get_app_store_versions(includes: "build").each do |v| UI.message("#{v.version_string} — #{v.app_store_state} — release: #{v.release_type} — build: #{v.build&.version}") end + + UI.header("Recent TestFlight builds") + Spaceship::ConnectAPI::Build.all(app_id: app.id, limit: 5, sort: "-uploadedDate").each do |b| + UI.message("build #{b.version} — #{b.processing_state} — expired: #{b.expired} — #{b.uploaded_date}") + end end # For a build that is already on TestFlight: `release` would rebuild it and diff --git a/fastlane/README.md b/fastlane/README.md index 40ec404..795b23e 100644 --- a/fastlane/README.md +++ b/fastlane/README.md @@ -39,6 +39,14 @@ Show the latest TestFlight beta feedback (tester reports and crashes) Download the crash log of a TestFlight feedback submission (id from `feedback`) +### ios groups + +```sh +[bundle exec] fastlane ios groups +``` + +temp + ### ios status ```sh