Class: Fastlane::Actions::EnProfileNameAction
- Inherits:
-
Action
- Object
- Action
- Fastlane::Actions::EnProfileNameAction
- Defined in:
- lib/fastlane/plugin/ciutils/actions/en_profile_name.rb
Documentation collapse
- .authors ⇒ Object
- .available_options ⇒ Object
- .description ⇒ Object
- .is_supported?(platform) ⇒ Boolean
- .return_value ⇒ Object
Class Method Summary collapse
Class Method Details
.authors ⇒ Object
50 51 52 |
# File 'lib/fastlane/plugin/ciutils/actions/en_profile_name.rb', line 50 def self. ["Nicolae Ghimbovschi"] end |
.available_options ⇒ Object
33 34 35 36 37 38 39 40 41 42 43 44 |
# File 'lib/fastlane/plugin/ciutils/actions/en_profile_name.rb', line 33 def self. [ FastlaneCore::ConfigItem.new(key: :path, env_name: "FL_EN_PROFILE_PATH", description: "Path to the provisioning profile", optional: true), FastlaneCore::ConfigItem.new(key: :uuid, env_name: "FL_EN_PROFILE_UUID", description: "The UUID of the provisioning profile from 'Provisioning Profiles' folder", optional: true) ] end |
.description ⇒ Object
29 30 31 |
# File 'lib/fastlane/plugin/ciutils/actions/en_profile_name.rb', line 29 def self.description "A short description with <= 80 characters of what this action does" end |
.is_supported?(platform) ⇒ Boolean
54 55 56 |
# File 'lib/fastlane/plugin/ciutils/actions/en_profile_name.rb', line 54 def self.is_supported?(platform) platform == :ios end |
.return_value ⇒ Object
46 47 48 |
# File 'lib/fastlane/plugin/ciutils/actions/en_profile_name.rb', line 46 def self.return_value "Provisioning profile name" end |
.run(params) ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/fastlane/plugin/ciutils/actions/en_profile_name.rb', line 4 def self.run(params) file_path = params[:path] profile_name = "" unless file_path file_uuid = params[:uuid] file_path = "~/Library/MobileDevice/Provisioning Profiles/#{file_uuid}.mobileprovision" file_path = File.(file_path) end if File.exist?(file_path) profile_xml_data = Fastlane::Actions.sh "security cms -D -i '#{file_path}'", log: false profile_data = Plist.parse_xml(profile_xml_data) profile_name = profile_data['Name'] else UI.user_error! "Could not find the specified profile at path '#{file_path}'" end profile_name end |