fastlane_core 0.48.1 → 0.48.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3ea8d74ee1ce721295375f5a126b3561078c7a91
4
- data.tar.gz: bc7199c387cedd346a5d86a2be9c3daa870ad008
3
+ metadata.gz: ff906faf7126e901cd09d4f4a1be9738c5175191
4
+ data.tar.gz: 00efc487a9990cc251ba06d2765ad12e90ad64c0
5
5
  SHA512:
6
- metadata.gz: 597401ffd1a6cba13799d67dbce1f890eab8689d5b2e90a2907782374d04cccd40b081859d6e72247c5c4e0323301646bb5c09f0f923560af753151e0582d02d
7
- data.tar.gz: 61f9c88f956c3dce7c70ef77eee7a35a1a722dc661ca9f9b85efcaa8d882302aa134e3dc3efb824557df0cbe1c022df9a076322e7a508885b688d84671cfad6e
6
+ metadata.gz: e8c780f75d3abfdeffaaf3629e36307e00ee08ada9c36a8e232144e92eef6fde8014c80385fff206d19c451ceae0e31dfc04b6c1d4cc1e4feae481e7720ff4da
7
+ data.tar.gz: ad0d9d8db1ec0a01c6be13f5d5274c4047fe8c4e55e77182de185b08acb4a61084a58b4304fa62a12ff6b276546df4a966464ed3e0650abd92aca2532a314269
@@ -15,7 +15,11 @@ module FastlaneCore
15
15
  attr_accessor :config_file_name
16
16
 
17
17
  def self.create(available_options, values)
18
+ UI.user_error!("values parameter must be a hash") unless values.kind_of?(Hash)
18
19
  v = values.dup
20
+ v.each do |key, val|
21
+ v[key] = val.dup if val.kind_of?(String) # this is necessary when fetching a value from an environment variable
22
+ end
19
23
 
20
24
  if v.kind_of?(Hash) && available_options.kind_of?(Array) # we only want to deal with the new configuration system
21
25
  # Now see if --verbose would be a valid input
@@ -47,7 +51,7 @@ module FastlaneCore
47
51
  @available_options.each do |item|
48
52
  UI.user_error!("available_options parameter must be an array of ConfigItems. Found #{item.class}.") unless item.kind_of? ConfigItem
49
53
  end
50
- UI.user_error!("values parameter must be a hash") unless @values.kind_of? Hash
54
+ UI.user_error!("values parameter must be a hash") unless @values.kind_of?(Hash)
51
55
  end
52
56
 
53
57
  def verify_value_exists
@@ -27,6 +27,7 @@ module FastlaneCore
27
27
  end
28
28
 
29
29
  def self.fetch_info_plist_file(path)
30
+ UI.user_error!("Could not find file at path '#{path}'") unless File.exist?(path)
30
31
  Zip::File.open(path) do |zipfile|
31
32
  file = zipfile.glob('**/Payload/*.app/Info.plist').first
32
33
  return nil unless file
@@ -348,7 +348,7 @@ module FastlaneCore
348
348
  actual_dir = File.join(dir, "#{app_id}.itmsp")
349
349
 
350
350
  UI.message("Going to upload updated app to iTunes Connect")
351
- UI.success("This might take a few minutes, please don't interrupt the script")
351
+ UI.success("This might take a few minutes. Please don't interrupt the script.")
352
352
 
353
353
  command = @transporter_executor.build_upload_command(@user, @password, actual_dir, @provider_short_name)
354
354
  UI.verbose(@transporter_executor.build_upload_command(@user, 'YourPassword', actual_dir, @provider_short_name))
@@ -66,10 +66,19 @@ module FastlaneCore
66
66
  # The config object containing the scheme, configuration, etc.
67
67
  attr_accessor :options
68
68
 
69
+ # Should the output of xcodebuild commands be silenced?
70
+ attr_accessor :xcodebuild_list_silent
71
+
72
+ # Should we redirect stderr to /dev/null for xcodebuild commands?
73
+ # Gets rid of annoying plugin info warnings.
74
+ attr_accessor :xcodebuild_suppress_stderr
75
+
69
76
  def initialize(options)
70
77
  self.options = options
71
78
  self.path = File.expand_path(options[:workspace] || options[:project])
72
79
  self.is_workspace = (options[:workspace].to_s.length > 0)
80
+ self.xcodebuild_list_silent = options[:xcodebuild_list_silent]
81
+ self.xcodebuild_suppress_stderr = options[:xcodebuild_suppress_stderr]
73
82
 
74
83
  if !path or !File.directory?(path)
75
84
  UI.user_error!("Could not find project at path '#{path}'")
@@ -166,6 +175,7 @@ module FastlaneCore
166
175
  def mac?
167
176
  # Some projects have different values... we have to look for all of them
168
177
  return true if build_settings(key: "PLATFORM_NAME") == "macosx"
178
+ return true if build_settings(key: "PLATFORM_DISPLAY_NAME") == "macOS"
169
179
  return true if build_settings(key: "PLATFORM_DISPLAY_NAME") == "OS X"
170
180
  false
171
181
  end
@@ -193,13 +203,19 @@ module FastlaneCore
193
203
  # @!group Raw Access
194
204
  #####################################################
195
205
 
206
+ def build_xcodebuild_showbuildsettings_command
207
+ # We also need to pass the workspace and scheme to this command
208
+ command = "xcodebuild -showBuildSettings #{xcodebuild_parameters.join(' ')}"
209
+ command += " 2> /dev/null" if xcodebuild_suppress_stderr
210
+ command
211
+ end
212
+
196
213
  # Get the build settings for our project
197
214
  # this is used to properly get the DerivedData folder
198
215
  # @param [String] The key of which we want the value for (e.g. "PRODUCT_NAME")
199
216
  def build_settings(key: nil, optional: true)
200
217
  unless @build_settings
201
- # We also need to pass the workspace and scheme to this command
202
- command = "xcrun xcodebuild -showBuildSettings #{xcodebuild_parameters.join(' ')}"
218
+ command = build_xcodebuild_showbuildsettings_command
203
219
  @build_settings = Helper.backticks(command, print: false)
204
220
  end
205
221
 
@@ -222,6 +238,15 @@ module FastlaneCore
222
238
  build_settings(key: key, optional: optional)
223
239
  end
224
240
 
241
+ def build_xcodebuild_list_command
242
+ # Unfortunately since we pass the workspace we also get all the
243
+ # schemes generated by CocoaPods
244
+ options = xcodebuild_parameters.delete_if { |a| a.to_s.include? "scheme" }
245
+ command = "xcodebuild -list #{options.join(' ')}"
246
+ command += " 2> /dev/null" if xcodebuild_suppress_stderr
247
+ command
248
+ end
249
+
225
250
  def raw_info(silent: false)
226
251
  # Examples:
227
252
 
@@ -253,11 +278,7 @@ module FastlaneCore
253
278
 
254
279
  return @raw if @raw
255
280
 
256
- # Unfortunately since we pass the workspace we also get all the
257
- # schemes generated by CocoaPods
258
-
259
- options = xcodebuild_parameters.delete_if { |a| a.to_s.include? "scheme" }
260
- command = "xcrun xcodebuild -list #{options.join(' ')}"
281
+ command = build_xcodebuild_list_command
261
282
  UI.important(command) unless silent
262
283
 
263
284
  # xcode >= 6 might hang here if the user schemes are missing
@@ -293,7 +314,7 @@ module FastlaneCore
293
314
 
294
315
  def parsed_info
295
316
  unless @parsed_info
296
- @parsed_info = FastlaneCore::XcodebuildListOutputParser.new(raw_info)
317
+ @parsed_info = FastlaneCore::XcodebuildListOutputParser.new(raw_info(silent: xcodebuild_list_silent))
297
318
  end
298
319
  @parsed_info
299
320
  end
@@ -1,3 +1,3 @@
1
1
  module FastlaneCore
2
- VERSION = "0.48.1".freeze
2
+ VERSION = "0.48.2".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane_core
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.48.1
4
+ version: 0.48.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Felix Krause
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-06-30 00:00:00.000000000 Z
11
+ date: 2016-07-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json
@@ -408,7 +408,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
408
408
  version: '0'
409
409
  requirements: []
410
410
  rubyforge_project:
411
- rubygems_version: 2.5.1
411
+ rubygems_version: 2.4.5.1
412
412
  signing_key:
413
413
  specification_version: 4
414
414
  summary: Contains all shared code/dependencies of the fastlane.tools