gym/lib/gym/detect_values.rb in fastlane-2.42.0 vs gym/lib/gym/detect_values.rb in fastlane-2.43.0.beta.20170629010015
- old
+ new
@@ -11,24 +11,16 @@
config.load_configuration_file(Gym.gymfile_name)
# Detect the project
FastlaneCore::Project.detect_projects(config)
Gym.project = FastlaneCore::Project.new(config)
- detect_provisioning_profile
# Go into the project's folder, as there might be a Gymfile there
Dir.chdir(File.expand_path("..", Gym.project.path)) do
config.load_configuration_file(Gym.gymfile_name)
end
- config[:use_legacy_build_api] = true if Xcode.pre_7?
-
- if config[:use_legacy_build_api]
- UI.deprecated("the use_legacy_build_api option is deprecated")
- UI.deprecated("it should not be used anymore - e.g.: if you use app-extensions")
- end
-
detect_scheme
detect_platform # we can only do that *after* we have the scheme
detect_configuration
detect_toolchain
@@ -58,31 +50,9 @@
File.expand_path("~/Library/Preferences/com.apple.dt.Xcode.plist")
end
def self.xcode_preferences_dictionary(path)
CFPropertyList.native_types(CFPropertyList::List.new(file: path).value)
- end
-
- def self.detect_provisioning_profile
- if Gym.config[:provisioning_profile_path].nil?
- return unless Gym.config[:use_legacy_build_api] # we only want to auto-detect the profile when using the legacy build API
-
- Dir.chdir(File.expand_path("..", Gym.project.path)) do
- profiles = Dir["*.mobileprovision"]
- if profiles.count == 1
- profile = File.expand_path(profiles.last)
- elsif profiles.count > 1
- UI.message "Found more than one provisioning profile in the project directory:"
- profile = choose(*profiles)
- end
-
- Gym.config[:provisioning_profile_path] = profile
- end
- end
-
- if Gym.config[:provisioning_profile_path]
- FastlaneCore::ProvisioningProfile.install(Gym.config[:provisioning_profile_path])
- end
end
def self.detect_scheme
Gym.project.select_scheme
end