default_platform(:ios)

lane :deploy do
  # Adjust bundle configuration profiles dynamically without touching class identifiers
  update_app_identifier(
    xcodeproj: "App.xcodeproj",
    plist_path: "App/Info.plist",
    app_identifier: ENV["TARGET_PACKAGE_ID"]
  )

  build_app(scheme: "App", export_method: "app-store")
  upload_to_testflight(app_identifier: ENV["TARGET_PACKAGE_ID"], skip_waiting_for_build_processing: true)
end
