cocoapods-core 1.6.0.beta.1 → 1.6.0.beta.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
  SHA256:
3
- metadata.gz: 0dae9d3dece7425ab43ea990f84a8bbe4600503e1f46d19130448e3717ef400b
4
- data.tar.gz: 7410712d03ed8f2e9dd6da1474d9381bb7a41b42a0acd9841481edbe379d5854
3
+ metadata.gz: 0afc2b42bd9023c362660d1bf6319d82e11adc16881b3b32fe28f412e1cae616
4
+ data.tar.gz: b76bd25972cb5b052938c05219b9aa859e13721de0e22f06f1012524fd535f8e
5
5
  SHA512:
6
- metadata.gz: 5c8cca08c3b62e15490c366c4798fa36873ef24896a2de729e473985db4f9bb1df80886e0c00da717058a03821afe82785b46204fb4dc4a41f2095deba6df700
7
- data.tar.gz: 3b49fa4dc1ad035ef0ae6c96a74977d53f70a62886965d3ad5924c4fac137061b5ea149a3e3d1b1dcf3dc3e8cdc51aa5fc3cd857560192977b85a0c006428b5c
6
+ metadata.gz: '019d4fa7c2faab7bea1ae65235c95f706d628f6e801c9d8ff14527132b4b22cb974b20bd5ac6d748cdca4439f13f957e33c4a905a5b5d4de1bac776dd43674a1'
7
+ data.tar.gz: 381cc2e97f447fbfe702a95a0a897456991f627789bde825d5b0ef930d361dfb7281173658228687405a41a3dfa989b23dcf8d02d32f13f95e8dee011bb72147
@@ -1,5 +1,5 @@
1
1
  module Pod
2
2
  # The version of the cocoapods-core.
3
3
  #
4
- CORE_VERSION = '1.6.0.beta.1'.freeze unless defined? Pod::CORE_VERSION
4
+ CORE_VERSION = '1.6.0.beta.2'.freeze unless defined? Pod::CORE_VERSION
5
5
  end
@@ -307,10 +307,6 @@ module Pod
307
307
 
308
308
  # Configures a new Podfile from the given YAML representation.
309
309
  #
310
- # @param [String] yaml
311
- # The YAML encoded hash which contains the information of the
312
- # Podfile.
313
- #
314
310
  # @param [Pathname] path
315
311
  # The path from which the Podfile is loaded.
316
312
  #
@@ -586,7 +586,7 @@ module Pod
586
586
  name = :osx if name == :macos
587
587
  unless [:ios, :osx, :tvos, :watchos].include?(name)
588
588
  raise StandardError, "Unsupported platform `#{name}`. Platform " \
589
- 'must be `:ios`, `:osx`, `:tvos`, or `:watchos`.'
589
+ 'must be `:ios`, `:osx`, `:macos`, `:tvos`, or `:watchos`.'
590
590
  end
591
591
 
592
592
  if target
@@ -663,15 +663,24 @@ module Pod
663
663
  # @return [void]
664
664
  #
665
665
  def store_podspec(options = nil)
666
- if options
667
- unless options.keys.all? { |key| [:name, :path].include?(key) }
668
- raise StandardError, 'Unrecognized options for the podspec ' \
669
- "method `#{options}`"
666
+ options ||= {}
667
+ unless options.keys.all? { |key| [:name, :path, :subspecs, :subspec].include?(key) }
668
+ raise StandardError, 'Unrecognized options for the podspec ' \
669
+ "method `#{options}`"
670
+ end
671
+ if subspec_name = options[:subspec]
672
+ unless subspec_name.is_a?(String)
673
+ raise StandardError, "Option `:subspec => #{subspec_name.inspect}` should be a String"
674
+ end
675
+ end
676
+ if subspec_names = options[:subspecs]
677
+ if !subspec_names.is_a?(Array) || !subspec_names.all? { |name| name.is_a? String }
678
+ raise StandardError, "Option `:subspecs => #{subspec_names.inspect}` " \
679
+ 'should be an Array of Strings'
670
680
  end
671
- get_hash_value('podspecs', []) << options
672
- else
673
- get_hash_value('podspecs', []) << { :autodetect => true }
674
681
  end
682
+ options[:autodetect] = true if !options.include?(:name) && !options.include?(:path)
683
+ get_hash_value('podspecs', []) << options
675
684
  end
676
685
 
677
686
  #--------------------------------------#
@@ -907,9 +916,18 @@ module Pod
907
916
  podspecs.map do |options|
908
917
  file = podspec_path_from_options(options)
909
918
  spec = Specification.from_file(file)
910
- all_specs = [spec, *spec.recursive_subspecs]
911
- all_deps = all_specs.map { |s| s.dependencies(platform) }.flatten
912
- all_deps.reject { |dep| dep.root_name == spec.root.name }
919
+ subspec_names = options[:subspecs] || options[:subspec]
920
+ specs = if subspec_names.blank?
921
+ [spec]
922
+ else
923
+ subspec_names = [subspec_names] if subspec_names.is_a?(String)
924
+ subspec_names.map { |subspec_name| spec.subspec_by_name("#{spec.name}/#{subspec_name}") }
925
+ end
926
+ specs.map do |subspec|
927
+ all_specs = [subspec, *subspec.recursive_subspecs]
928
+ all_deps = all_specs.map { |s| s.dependencies(platform) }.flatten
929
+ all_deps.reject { |dep| dep.root_name == subspec.root.name }
930
+ end.flatten
913
931
  end.flatten.uniq
914
932
  end
915
933
 
@@ -988,13 +988,13 @@ module Pod
988
988
  #
989
989
  # @example
990
990
  #
991
- # spec.script_phase = { :name => 'Hello World', :script => 'puts "Hello World"', :shell_path => '/usr/bin/ruby' } }
991
+ # spec.script_phase = { :name => 'Hello World', :script => 'puts "Hello World"', :shell_path => '/usr/bin/ruby' }
992
992
  #
993
993
  # @example
994
994
  #
995
995
  # spec.script_phases = [
996
996
  # { :name => 'Hello World', :script => 'echo "Hello World"' },
997
- # { :name => 'Hello Ruby World', :script => 'puts "Hello World"', :shell_path => '/usr/bin/ruby' } },
997
+ # { :name => 'Hello Ruby World', :script => 'puts "Hello World"', :shell_path => '/usr/bin/ruby' },
998
998
  # ]
999
999
  #
1000
1000
  # @param [Array<Hash{Symbol=>String}>] script_phases
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cocoapods-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.0.beta.1
4
+ version: 1.6.0.beta.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eloy Duran
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2018-08-16 00:00:00.000000000 Z
12
+ date: 2018-10-17 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: activesupport