fastlane/lib/fastlane/actions/build_app.rb in fastlane_hotfix-2.165.1 vs fastlane/lib/fastlane/actions/build_app.rb in fastlane_hotfix-2.187.0
- old
+ new
@@ -6,10 +6,11 @@
DSYM_OUTPUT_PATH ||= :DSYM_OUTPUT_PATH
XCODEBUILD_ARCHIVE ||= :XCODEBUILD_ARCHIVE # originally defined in XcodebuildAction
end
class BuildAppAction < Action
+ # rubocop:disable Metrics/PerceivedComplexity
def self.run(values)
require 'gym'
unless Actions.lane_context[SharedValues::SIGH_PROFILE_TYPE].to_s == "development"
values[:export_method] ||= Actions.lane_context[SharedValues::SIGH_PROFILE_TYPE]
@@ -48,11 +49,12 @@
values[:export_options][:provisioningProfiles] ||= {}
Actions.lane_context[SharedValues::SIGH_PROFILE_PATHS].each do |profile_path|
begin
profile = FastlaneCore::ProvisioningProfile.parse(profile_path)
app_id_prefix = profile["ApplicationIdentifierPrefix"].first
- bundle_id = profile["Entitlements"]["application-identifier"].gsub("#{app_id_prefix}.", "")
+ entitlements = profile["Entitlements"]
+ bundle_id = (entitlements["application-identifier"] || entitlements["com.apple.application-identifier"]).gsub("#{app_id_prefix}.", "")
values[:export_options][:provisioningProfiles][bundle_id] = profile["Name"]
rescue => ex
UI.error("Couldn't load profile at path: #{profile_path}")
UI.error(ex)
UI.verbose(ex.backtrace.join("\n"))
@@ -114,9 +116,13 @@
]
end
def self.return_value
"The absolute path to the generated ipa file"
+ end
+
+ def self.return_type
+ :string
end
def self.author
"KrauseFx"
end