Class: Fastlane::Actions::AddAllDevicesToProvisioningProfilesAction
- Inherits:
-
Action
- Object
- Action
- Fastlane::Actions::AddAllDevicesToProvisioningProfilesAction
- Defined in:
- lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/add_devices_to_provisioning_profiles.rb
Documentation collapse
- .authors ⇒ Object
- .available_options ⇒ Object
- .description ⇒ Object
- .details ⇒ Object
- .is_supported?(platform) ⇒ Boolean
- .output ⇒ Object
- .return_value ⇒ Object
Class Method Summary collapse
Class Method Details
.authors ⇒ Object
69 70 71 72 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/add_devices_to_provisioning_profiles.rb', line 69 def self. # So no one will ever forget your contribution to fastlane :) You are awesome btw! ['Automattic'] end |
.available_options ⇒ Object
40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/add_devices_to_provisioning_profiles.rb', line 40 def self. [ FastlaneCore::ConfigItem.new( key: :app_identifier, description: 'List of App Identifiers that should contain the new device identifier', is_string: false, verify_block: proc do |value| UI.user_error!('You must provide an array of bundle identifiers in `app_identifier`') if value.empty? end ), FastlaneCore::ConfigItem.new( key: :team_id, description: 'The team_id for the provisioning profiles', is_string: true, verify_block: proc do |value| UI.user_error!('You must provide a team ID in `team_id`') unless value && (!value.empty?) end ), ] end |
.description ⇒ Object
32 33 34 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/add_devices_to_provisioning_profiles.rb', line 32 def self.description 'Add devices to provisioning profiles' end |
.details ⇒ Object
36 37 38 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/add_devices_to_provisioning_profiles.rb', line 36 def self.details 'Add all iOS devices to any profiles associated with the provided bundle identifiers' end |
.is_supported?(platform) ⇒ Boolean
74 75 76 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/add_devices_to_provisioning_profiles.rb', line 74 def self.is_supported?(platform) platform == :ios end |
.output ⇒ Object
61 62 63 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/add_devices_to_provisioning_profiles.rb', line 61 def self.output # This lane doesn't provide variables that other lanes can consume. end |
.return_value ⇒ Object
65 66 67 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/add_devices_to_provisioning_profiles.rb', line 65 def self.return_value # If your method provides a return value, you can describe here what it does end |
.run(params) ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/add_devices_to_provisioning_profiles.rb', line 4 def self.run(params) require 'spaceship' Spaceship.login Spaceship.select_team(team_id: params[:team_id]) devices = Spaceship.device.all_ios_profile_devices params[:app_identifier].each do |identifier| Spaceship.provisioning_profile.find_by_bundle_id(bundle_id: identifier) .select do |profile| profile.is_a? Spaceship::Portal::ProvisioningProfile::Development end .tap do |profiles| UI.important "Warning: Unable to find any profiles associated with #{identifier}" unless profiles.length > 0 end .each do |profile| profile.devices = devices profile.update! UI.success "Applied #{devices.length} devices to #{profile.name}" end end end |