module Match
Constants
- Boolean
- DESCRIPTION
- Helper
- ROOT
- UI
Public Class Methods
cert_type_sym(type)
click to toggle source
# File match/lib/match/module.rb, line 25 def self.cert_type_sym(type) # To determine certificate types to fetch from the portal, we use `Sigh.certificate_types_for_profile_and_platform`, and it returns typed `Spaceship::ConnectAPI::Certificate::CertificateType` with the same values but uppercased, so we downcase them here type = type.to_s.downcase return :mac_installer_distribution if type == "mac_installer_distribution" return :developer_id_installer if type == "developer_id_installer" return :developer_id_application if type == "developer_id" return :enterprise if type == "enterprise" return :development if type == "development" return :distribution if ["adhoc", "appstore", "distribution"].include?(type) raise "Unknown cert type: '#{type}'" end
environments()
click to toggle source
# File match/lib/match/module.rb, line 13 def self.environments return %w(appstore adhoc development enterprise developer_id mac_installer_distribution developer_id_installer) end
profile_type_sym(type)
click to toggle source
# File match/lib/match/module.rb, line 21 def self.profile_type_sym(type) return type.to_sym end
profile_types(prov_type)
click to toggle source
Converts provisioning profile type (i.e. development, enterprise) to an array of profile types That can be used for filtering when using Spaceship::ConnectAPI::Profile
API
# File match/lib/match/module.rb, line 39 def self.profile_types(prov_type) case prov_type.to_sym when :appstore return [ Spaceship::ConnectAPI::Profile::ProfileType::IOS_APP_STORE, Spaceship::ConnectAPI::Profile::ProfileType::MAC_APP_STORE, Spaceship::ConnectAPI::Profile::ProfileType::TVOS_APP_STORE, Spaceship::ConnectAPI::Profile::ProfileType::MAC_CATALYST_APP_STORE ] when :development return [ Spaceship::ConnectAPI::Profile::ProfileType::IOS_APP_DEVELOPMENT, Spaceship::ConnectAPI::Profile::ProfileType::MAC_APP_DEVELOPMENT, Spaceship::ConnectAPI::Profile::ProfileType::TVOS_APP_DEVELOPMENT, Spaceship::ConnectAPI::Profile::ProfileType::MAC_CATALYST_APP_DEVELOPMENT ] when :enterprise profiles = [ Spaceship::ConnectAPI::Profile::ProfileType::IOS_APP_INHOUSE, Spaceship::ConnectAPI::Profile::ProfileType::TVOS_APP_INHOUSE ] # As of 2022-06-25, only available with Apple ID auth if Spaceship::ConnectAPI.token UI.important("Skipping #{Spaceship::ConnectAPI::Profile::ProfileType::MAC_APP_INHOUSE} and #{Spaceship::ConnectAPI::Profile::ProfileType::MAC_CATALYST_APP_INHOUSE}... only available with Apple ID auth") else profiles += [ Spaceship::ConnectAPI::Profile::ProfileType::MAC_APP_INHOUSE, Spaceship::ConnectAPI::Profile::ProfileType::MAC_CATALYST_APP_INHOUSE ] end return profiles when :adhoc return [ Spaceship::ConnectAPI::Profile::ProfileType::IOS_APP_ADHOC, Spaceship::ConnectAPI::Profile::ProfileType::TVOS_APP_ADHOC ] when :developer_id return [ Spaceship::ConnectAPI::Profile::ProfileType::MAC_APP_DIRECT, Spaceship::ConnectAPI::Profile::ProfileType::MAC_CATALYST_APP_DIRECT ] else raise "Unknown provisioning type '#{prov_type}'" end end
storage_modes()
click to toggle source
# File match/lib/match/module.rb, line 17 def self.storage_modes return %w(git google_cloud s3 gitlab_secure_files) end