spaceship/lib/spaceship/connect_api/models/device.rb in fastlane-2.219.0 vs spaceship/lib/spaceship/connect_api/models/device.rb in fastlane-2.220.0

- old
+ new

@@ -28,13 +28,15 @@ IPAD = "IPAD" IPHONE = "IPHONE" IPOD = "IPOD" APPLE_TV = "APPLE_TV" MAC = "MAC" + APPLE_VISION_PRO = "APPLE_VISION_PRO" - # As of 2022-11-12, this is not officially supported by App Store Connect API + # As of 2024-03-08, this is not _officially_ supported by App Store Connect API (according to API docs)—yet still used in the API responses APPLE_SILICON_MAC = "APPLE_SILICON_MAC" + INTEL_MAC = "INTEL_MAC" end module Status ENABLED = "ENABLED" DISABLED = "DISABLED" @@ -66,11 +68,11 @@ include_mac_in_profiles &&= platform == :ios device_platform = case platform when :osx, :macos, :mac Spaceship::ConnectAPI::Platform::MAC_OS - when :ios + when :ios, :tvos, :xros, :visionos Spaceship::ConnectAPI::Platform::IOS when :catalyst Spaceship::ConnectAPI::Platform::MAC_OS end @@ -84,19 +86,22 @@ when :ios [ Spaceship::ConnectAPI::Device::DeviceClass::IPAD, Spaceship::ConnectAPI::Device::DeviceClass::IPHONE, Spaceship::ConnectAPI::Device::DeviceClass::IPOD, - Spaceship::ConnectAPI::Device::DeviceClass::APPLE_WATCH + Spaceship::ConnectAPI::Device::DeviceClass::APPLE_WATCH, + Spaceship::ConnectAPI::Device::DeviceClass::APPLE_VISION_PRO ] when :tvos [ Spaceship::ConnectAPI::Device::DeviceClass::APPLE_TV ] when :macos, :catalyst [ - Spaceship::ConnectAPI::Device::DeviceClass::MAC + Spaceship::ConnectAPI::Device::DeviceClass::MAC, + Spaceship::ConnectAPI::Device::DeviceClass::APPLE_SILICON_MAC, + Spaceship::ConnectAPI::Device::DeviceClass::INTEL_MAC ] else [] end @@ -104,12 +109,12 @@ device_classes << Spaceship::ConnectAPI::Device::DeviceClass::APPLE_SILICON_MAC device_platforms << Spaceship::ConnectAPI::Platform::MAC_OS end filter = { - status: Spaceship::ConnectAPI::Device::Status::ENABLED, - platform: device_platforms.uniq.join(',') + status: Spaceship::ConnectAPI::Device::Status::ENABLED } + filter[:platform] = device_platforms.uniq.join(',') unless device_platforms.empty? devices = Spaceship::ConnectAPI::Device.all( client: client, filter: filter )