lib/gym/options.rb in gym-1.5.0 vs lib/gym/options.rb in gym-1.6.0

- old
+ new

@@ -19,10 +19,14 @@ verify_block: proc do |value| v = File.expand_path(value.to_s) UI.user_error!("Workspace file not found at path '#{v}'") unless File.exist?(v) UI.user_error!("Workspace file invalid") unless File.directory?(v) UI.user_error!("Workspace file is not a workspace, must end with .xcworkspace") unless v.include?(".xcworkspace") + end, + conflicting_options: [:project], + conflict_block: proc do |value| + UI.user_error!("You can only pass either a 'workspace' or a '#{value.key}', not both") end), FastlaneCore::ConfigItem.new(key: :project, short_option: "-p", optional: true, env_name: "GYM_PROJECT", @@ -30,10 +34,14 @@ verify_block: proc do |value| v = File.expand_path(value.to_s) UI.user_error!("Project file not found at path '#{v}'") unless File.exist?(v) UI.user_error!("Project file invalid") unless File.directory?(v) UI.user_error!("Project file is not a project file, must end with .xcodeproj") unless v.include?(".xcodeproj") + end, + conflicting_options: [:workspace], + conflict_block: proc do |value| + UI.user_error!("You can only pass either a 'project' or a '#{value.key}', not both") end), FastlaneCore::ConfigItem.new(key: :scheme, short_option: "-s", optional: true, env_name: "GYM_SCHEME", @@ -75,18 +83,18 @@ optional: true), FastlaneCore::ConfigItem.new(key: :include_symbols, short_option: "-m", env_name: "GYM_INCLUDE_SYMBOLS", description: "Should the ipa file include symbols?", - default_value: true, - is_string: false), + is_string: false, + optional: true), FastlaneCore::ConfigItem.new(key: :include_bitcode, short_option: "-z", env_name: "GYM_INCLUDE_BITCODE", description: "Should the ipa include bitcode?", - default_value: false, - is_string: false), + is_string: false, + optional: true), FastlaneCore::ConfigItem.new(key: :use_legacy_build_api, env_name: "GYM_USE_LEGACY_BUILD_API", description: "Don't use the new API because of https://openradar.appspot.com/radar?id=4952000420642816", default_value: false, is_string: false, @@ -102,9 +110,18 @@ is_string: true, optional: true, verify_block: proc do |value| av = %w(app-store ad-hoc package enterprise development developer-id) UI.user_error!("Unsupported export_method, must be: #{av}") unless av.include?(value) + end), + FastlaneCore::ConfigItem.new(key: :export_options, + env_name: "GYM_EXPORT_OPTIONS", + description: "Specifies path to export options plist. User xcodebuild -help to print the full set of available options", + is_string: false, + optional: true, + conflicting_options: [:use_legacy_build_api], + conflict_block: proc do |value| + UI.user_error!("'#{value.key}' must be false to use 'export_options'") end), # Very optional FastlaneCore::ConfigItem.new(key: :archive_path, short_option: "-b",