cocoapods 0.39.0.beta.4 → 0.39.0.beta.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +77 -0
  3. data/lib/cocoapods/command.rb +1 -2
  4. data/lib/cocoapods/command/init.rb +3 -1
  5. data/lib/cocoapods/command/repo/add.rb +43 -8
  6. data/lib/cocoapods/command/spec.rb +3 -3
  7. data/lib/cocoapods/command/spec/cat.rb +1 -1
  8. data/lib/cocoapods/command/spec/create.rb +4 -2
  9. data/lib/cocoapods/command/spec/edit.rb +1 -1
  10. data/lib/cocoapods/downloader.rb +1 -1
  11. data/lib/cocoapods/downloader/request.rb +1 -1
  12. data/lib/cocoapods/executable.rb +7 -4
  13. data/lib/cocoapods/gem_version.rb +1 -1
  14. data/lib/cocoapods/generator/acknowledgements.rb +1 -1
  15. data/lib/cocoapods/generator/copy_resources_script.rb +1 -0
  16. data/lib/cocoapods/generator/embed_frameworks_script.rb +10 -8
  17. data/lib/cocoapods/generator/header.rb +1 -0
  18. data/lib/cocoapods/generator/xcconfig/aggregate_xcconfig.rb +3 -0
  19. data/lib/cocoapods/generator/xcconfig/pod_xcconfig.rb +1 -1
  20. data/lib/cocoapods/generator/xcconfig/xcconfig_helper.rb +3 -8
  21. data/lib/cocoapods/hooks_manager.rb +1 -1
  22. data/lib/cocoapods/installer.rb +13 -1
  23. data/lib/cocoapods/installer/analyzer.rb +8 -11
  24. data/lib/cocoapods/installer/analyzer/specs_state.rb +6 -6
  25. data/lib/cocoapods/installer/post_install_hooks_context.rb +1 -1
  26. data/lib/cocoapods/installer/target_installer/pod_target_installer.rb +6 -10
  27. data/lib/cocoapods/installer/user_project_integrator/target_integrator.rb +2 -2
  28. data/lib/cocoapods/resolver.rb +16 -1
  29. data/lib/cocoapods/sandbox/file_accessor.rb +1 -1
  30. data/lib/cocoapods/sandbox/path_list.rb +1 -1
  31. data/lib/cocoapods/sources_manager.rb +5 -3
  32. data/lib/cocoapods/target/pod_target.rb +1 -1
  33. data/lib/cocoapods/user_interface.rb +3 -3
  34. data/lib/cocoapods/validator.rb +12 -1
  35. metadata +46 -33
  36. data/lib/cocoapods/command/search.rb +0 -101
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b37d2db8457fdd54c70e37273ccf0cd2f2f4848a
4
- data.tar.gz: 9a545fa271be99539ae2a47aca529a550b4627d1
3
+ metadata.gz: d34fbbd05497ec88b132304db391872b725f0976
4
+ data.tar.gz: 07097a4bea5c3ddfcf65fc77de8ec0968ef8aa31
5
5
  SHA512:
6
- metadata.gz: 1c2e3a8e261f3d6c0cd0ba5987de648703168b67021a9a6ae75dc6e5364c6d0929d91fcad2defd9aced52088e5bc948e4b3fd633c3bf8bfd981be3bcef482b7c
7
- data.tar.gz: edec194b42c0a81e7fa1b8af59c3c6d8508ee95cf1641d41261a1d17bf6c224f329e311051f431a02030bc4a1a8d6c64ea21e74a4a0b49dabfad40b7b5633fc7
6
+ metadata.gz: e749c9394f1dc06fc4e06bb64b1e9b9d6602d9381f23a450cf8688c8a834f167a8c3b45b6a41c85e964de30db7d3614a7f3e27a4125608c9fcaa8b96d3638a56
7
+ data.tar.gz: 1aaca2db33e7209f5cd93aeb44159f3fd85351aa807f2e9bd0edb6e5a1c4749ac2979f4a7fe21787398e3fe1b62a39754342d202e10f0197aa18b0d457c2ccfd
@@ -4,6 +4,83 @@ To install or update CocoaPods see this [guide](http://docs.cocoapods.org/guides
4
4
 
5
5
  To install release candidates run `[sudo] gem install cocoapods --pre`
6
6
 
7
+ ## 0.39.0.beta.5 (2015-10-01)
8
+
9
+ ##### Breaking
10
+
11
+ * Activesupport 4 is now required, breaking compatibility with applications
12
+ locked to `3.x.y`.
13
+
14
+ ##### Enhancements
15
+
16
+ * The `EMBEDDED_CONTENT_CONTAINS_SWIFT` build setting will now be set when
17
+ appropriate.
18
+ [Samuel Giddins](https://github.com/segiddins)
19
+
20
+ * The embed frameworks script will no longer manually copy over the Swift
21
+ runtime libraries on Xcode 7 and later.
22
+ [Samuel Giddins](https://github.com/segiddins)
23
+ [earltedly](https://github.com/segiddins)
24
+ [DJ Tarazona](https://github.com/djtarazona)
25
+ [#4188](https://github.com/CocoaPods/CocoaPods/issues/4188)
26
+
27
+ * A post-install summary of the pods installed is now printed.
28
+ [Samuel Giddins](https://github.com/segiddins)
29
+ [#4124](https://github.com/CocoaPods/CocoaPods/issues/4124)
30
+
31
+ ##### Bug Fixes
32
+
33
+ * Give a meaningful message for the case where there is no available stable
34
+ version for a pod, and there is no explicit version requirement.
35
+ [Muhammed Yavuz Nuzumlalı](https://github.com/manuyavuz)
36
+ [#4197](https://github.com/CocoaPods/CocoaPods/issues/4197)
37
+
38
+ * Use `watchsimulator` when validating pods with the watchOS platform.
39
+ [Thomas Kollbach](https://github.com/toto)
40
+ [#4130](https://github.com/CocoaPods/CocoaPods/issues/4130)
41
+
42
+ * C or C++ preprocessor output files with `.i` extension now have their compiler
43
+ flags set correctly.
44
+ [Andrea Aresu](https://github.com/aaresu/)
45
+
46
+ * Remove SDKROOT relative search path as it isn't needed anymore since XCTest.
47
+ [Boris Bügling](https://github.com/neonichu)
48
+ [#4219](https://github.com/CocoaPods/CocoaPods/issues/4219)
49
+
50
+ * Podfile generated by `pod init` now specifies iOS 8.0 as the default platform
51
+ and includes `use_frameworks!` for Swift projects.
52
+ [Jamie Evans](https://github.com/JamieREvans)
53
+
54
+ * Support for the new `tvos` platform.
55
+ [Boris Bügling](https://github.com/neonichu)
56
+ [#4152](https://github.com/CocoaPods/CocoaPods/pull/4152)
57
+
58
+ * Either generate just one pod target or generate it once for each target
59
+ definition.
60
+ [Marius Rackwitz](https://github.com/mrackwitz)
61
+ [#4034](https://github.com/CocoaPods/CocoaPods/issues/4034)
62
+
63
+ * Stop setting `DYLIB_CURRENT_VERSION`, `CURRENT_PROJECT_VERSION`, and
64
+ `DYLIB_COMPATIBILITY_VERSION` for pods integrated as dynamic frameworks.
65
+ [Samuel Giddins](https://github.com/segiddins)
66
+ [#4083](https://github.com/CocoaPods/CocoaPods/issues/4083)
67
+
68
+ * The headers folders paths for static library pods will be unset, fixing
69
+ validation when archives are uploaded to iTunes Connect.
70
+ [Boris Bügling](https://github.com/neonichu)
71
+ [Samuel Giddins](https://github.com/segiddins)
72
+ [#4119](https://github.com/CocoaPods/CocoaPods/issues/4119)
73
+
74
+ * Don't require the `platform` attribute for targets without any declared pods
75
+ when running `pod install --no-integrate`.
76
+ [Sylvain Guillopé](https://github.com/sguillope)
77
+ [#3151](https://github.com/CocoaPods/CocoaPods/issues/3151)
78
+
79
+ * Gracefully handle exception if creating the repos directory fails due to a
80
+ system error like a permission issue.
81
+ [Sylvain Guillopé](https://github.com/sguillope)
82
+ [#4177](https://github.com/CocoaPods/CocoaPods/issues/4177)
83
+
7
84
  ## 0.39.0.beta.4 (2015-09-02)
8
85
 
9
86
  ##### Bug Fixes
@@ -20,7 +20,6 @@ module Pod
20
20
  require 'cocoapods/command/outdated'
21
21
  require 'cocoapods/command/project'
22
22
  require 'cocoapods/command/repo'
23
- require 'cocoapods/command/search'
24
23
  require 'cocoapods/command/setup'
25
24
  require 'cocoapods/command/spec'
26
25
  require 'cocoapods/command/init'
@@ -37,7 +36,7 @@ module Pod
37
36
 
38
37
  def self.options
39
38
  [
40
- ['--silent', 'Show nothing'],
39
+ ['--silent', 'Show nothing'],
41
40
  ].concat(super)
42
41
  end
43
42
 
@@ -57,7 +57,9 @@ module Pod
57
57
  podfile << "xcodeproj '#{@project_path}'\n\n" if @project_path
58
58
  podfile << <<-PLATFORM.strip_heredoc
59
59
  # Uncomment this line to define a global platform for your project
60
- # platform :ios, '6.0'
60
+ # platform :ios, '8.0'
61
+ # Uncomment this line if you're using Swift
62
+ # use_frameworks!
61
63
  PLATFORM
62
64
 
63
65
  project.targets.each do |target|
@@ -23,7 +23,9 @@ module Pod
23
23
 
24
24
  def initialize(argv)
25
25
  @shallow = argv.flag?('shallow', false)
26
- @name, @url, @branch = argv.shift_argument, argv.shift_argument, argv.shift_argument
26
+ @name = argv.shift_argument
27
+ @url = argv.shift_argument
28
+ @branch = argv.shift_argument
27
29
  super
28
30
  end
29
31
 
@@ -37,16 +39,49 @@ module Pod
37
39
  def run
38
40
  prefix = @shallow ? 'Creating shallow clone of' : 'Cloning'
39
41
  UI.section("#{prefix} spec repo `#{@name}` from `#{@url}`#{" (branch `#{@branch}`)" if @branch}") do
40
- config.repos_dir.mkpath
41
- Dir.chdir(config.repos_dir) do
42
- command = ['clone', @url, @name]
43
- command << '--depth=1' if @shallow
44
- git!(command)
45
- end
46
- Dir.chdir(dir) { git!('checkout', @branch) } if @branch
42
+ create_repos_dir
43
+ clone_repo
44
+ checkout_branch
47
45
  SourcesManager.check_version_information(dir)
48
46
  end
49
47
  end
48
+
49
+ private
50
+
51
+ # Creates the repos directory specified in the configuration by
52
+ # `config.repos_dir`.
53
+ #
54
+ # @return [void]
55
+ #
56
+ # @raise If the directory cannot be created due to a system error.
57
+ #
58
+ def create_repos_dir
59
+ config.repos_dir.mkpath
60
+ rescue => e
61
+ raise Informative, "Could not create '#{config.repos_dir}', the CocoaPods repo cache directory.\n" \
62
+ "#{e.class.name}: #{e.message}"
63
+ end
64
+
65
+ # Clones the git spec-repo according to parameters passed to the
66
+ # command.
67
+ #
68
+ # @return [void]
69
+ #
70
+ def clone_repo
71
+ Dir.chdir(config.repos_dir) do
72
+ command = ['clone', @url, @name]
73
+ command << '--depth=1' if @shallow
74
+ git!(command)
75
+ end
76
+ end
77
+
78
+ # Checks out the branch of the git spec-repo if provided.
79
+ #
80
+ # @return [void]
81
+ #
82
+ def checkout_branch
83
+ Dir.chdir(dir) { git!('checkout', @branch) } if @branch
84
+ end
50
85
  end
51
86
  end
52
87
  end
@@ -48,7 +48,7 @@ module Pod
48
48
  set = sets.find { |s| s.name == spec }
49
49
  else
50
50
  names = sets.map(&:name) * ', '
51
- raise Informative, "More than one spec found for '#{ spec }':\n#{ names }"
51
+ raise Informative, "More than one spec found for '#{spec}':\n#{names}"
52
52
  end
53
53
 
54
54
  unless show_all
@@ -77,7 +77,7 @@ module Pod
77
77
 
78
78
  versions.each do |version|
79
79
  spec = source.specification(set.name, version)
80
- paths += "#{ pathname_from_spec(spec, source) }\n"
80
+ paths += "#{pathname_from_spec(spec, source)}\n"
81
81
  end
82
82
  end
83
83
 
@@ -102,7 +102,7 @@ module Pod
102
102
  end
103
103
 
104
104
  if !best_source || !best_version
105
- raise Informative, "Unable to locate highest known specification for `#{ set.name }'"
105
+ raise Informative, "Unable to locate highest known specification for `#{set.name}'"
106
106
  end
107
107
 
108
108
  [best_source.specification(set.name, best_version), best_source]
@@ -37,7 +37,7 @@ module Pod
37
37
  query = @use_regex ? @query : Regexp.escape(@query)
38
38
  filepath = if @show_all
39
39
  specs = get_path_of_spec(query, @show_all).split(/\n/)
40
- index = UI.choose_from_array(specs, "Which spec would you like to print [1-#{ specs.count }]? ")
40
+ index = UI.choose_from_array(specs, "Which spec would you like to print [1-#{specs.count}]? ")
41
41
  specs[index]
42
42
  else
43
43
  get_path_of_spec(query)
@@ -15,7 +15,8 @@ module Pod
15
15
  ]
16
16
 
17
17
  def initialize(argv)
18
- @name_or_url, @url = argv.shift_argument, argv.shift_argument
18
+ @name_or_url = argv.shift_argument
19
+ @url = argv.shift_argument
19
20
  super
20
21
  end
21
22
 
@@ -73,7 +74,7 @@ module Pod
73
74
  data[:name] = repo['name']
74
75
  data[:summary] = (repo['description'] || '').gsub(/["]/, '\"')
75
76
  data[:homepage] = (repo['homepage'] && !repo['homepage'].empty?) ? repo['homepage'] : repo['html_url']
76
- data[:author_name] = user['name'] || user['login']
77
+ data[:author_name] = user['name'] || user['login']
77
78
  data[:author_email] = user['email'] || 'email@address.com'
78
79
  data[:source_url] = repo['clone_url']
79
80
 
@@ -177,6 +178,7 @@ Pod::Spec.new do |s|
177
178
  # s.ios.deployment_target = "5.0"
178
179
  # s.osx.deployment_target = "10.7"
179
180
  # s.watchos.deployment_target = "2.0"
181
+ # s.tvos.deployment_target = "9.0"
180
182
 
181
183
 
182
184
  # ――― Source Location ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――― #
@@ -45,7 +45,7 @@ module Pod
45
45
  end
46
46
 
47
47
  exec_editor(filepath.to_s) if File.exist? filepath
48
- raise Informative, "#{ filepath } doesn't exist."
48
+ raise Informative, "#{filepath} doesn't exist."
49
49
  end
50
50
 
51
51
  # Looks up an executable in the search paths
@@ -34,7 +34,7 @@ module Pod
34
34
  result = cache.download_pod(request)
35
35
  else
36
36
  require 'cocoapods/installer/pod_source_preparer'
37
- result, _ = download_request(request, target)
37
+ result, = download_request(request, target)
38
38
  Installer::PodSourcePreparer.new(result.spec, result.location).prepare!
39
39
  end
40
40
 
@@ -68,7 +68,7 @@ module Pod
68
68
  # download request.
69
69
  #
70
70
  def slug(name: self.name, params: self.params, spec: self.spec)
71
- checksum = spec && spec.checksum && '-' << spec.checksum[0, 5]
71
+ checksum = spec && spec.checksum && '-' << spec.checksum[0, 5]
72
72
  if released_pod?
73
73
  "Release/#{name}/#{spec.version}#{checksum}"
74
74
  else
@@ -54,13 +54,16 @@ module Pod
54
54
 
55
55
  if Config.instance.verbose?
56
56
  UI.message("$ #{full_command}")
57
- stdout, stderr = Indenter.new(STDOUT), Indenter.new(STDERR)
57
+ stdout = Indenter.new(STDOUT)
58
+ stderr = Indenter.new(STDERR)
58
59
  else
59
- stdout, stderr = Indenter.new, Indenter.new
60
+ stdout = Indenter.new
61
+ stderr = Indenter.new
60
62
  end
61
63
 
62
64
  status = popen3(bin, command, stdout, stderr)
63
- stdout, stderr = stdout.join, stderr.join
65
+ stdout = stdout.join
66
+ stderr = stderr.join
64
67
  output = stdout + stderr
65
68
  unless status.success?
66
69
  if raise_on_failure
@@ -197,7 +200,7 @@ module Pod
197
200
  #
198
201
  def <<(value)
199
202
  super
200
- io << "#{ indent }#{ value }" if io
203
+ io << "#{indent}#{value}" if io
201
204
  end
202
205
  end
203
206
  end
@@ -1,5 +1,5 @@
1
1
  module Pod
2
2
  # The version of the cocoapods command line tool.
3
3
  #
4
- VERSION = '0.39.0.beta.4' unless defined? Pod::VERSION
4
+ VERSION = '0.39.0.beta.5' unless defined? Pod::VERSION
5
5
  end
@@ -77,7 +77,7 @@ module Pod
77
77
  if license_file.exist?
78
78
  text = IO.read(license_file)
79
79
  else
80
- UI.warn "Unable to read the license file `#{license_file }` " \
80
+ UI.warn "Unable to read the license file `#{license_file}` " \
81
81
  "for the spec `#{spec}`"
82
82
  end
83
83
  end
@@ -52,6 +52,7 @@ module Pod
52
52
  :ios => Version.new('6.0'),
53
53
  :osx => Version.new('10.8'),
54
54
  :watchos => Version.new('2.0'),
55
+ :tvos => Version.new('9.0'),
55
56
  }
56
57
 
57
58
  # @return [Bool] Whether the external strings file is supported by the
@@ -79,14 +79,16 @@ module Pod
79
79
  # Resign the code if required by the build settings to avoid unstable apps
80
80
  code_sign_if_enabled "${destination}/$(basename "$1")"
81
81
 
82
- # Embed linked Swift runtime libraries
83
- local swift_runtime_libs
84
- swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\\\/\\(.+dylib\\).*/\\\\1/g | uniq -u && exit ${PIPESTATUS[0]})
85
- for lib in $swift_runtime_libs; do
86
- echo "rsync -auv \\"${SWIFT_STDLIB_PATH}/${lib}\\" \\"${destination}\\""
87
- rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}"
88
- code_sign_if_enabled "${destination}/${lib}"
89
- done
82
+ # Embed linked Swift runtime libraries. No longer necessary as of Xcode 7.
83
+ if [ "${XCODE_VERSION_MAJOR}" -lt 7 ]; then
84
+ local swift_runtime_libs
85
+ swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\\\/\\(.+dylib\\).*/\\\\1/g | uniq -u && exit ${PIPESTATUS[0]})
86
+ for lib in $swift_runtime_libs; do
87
+ echo "rsync -auv \\"${SWIFT_STDLIB_PATH}/${lib}\\" \\"${destination}\\""
88
+ rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}"
89
+ code_sign_if_enabled "${destination}/${lib}"
90
+ done
91
+ fi
90
92
  }
91
93
 
92
94
  # Signs a framework with the provided identity
@@ -84,6 +84,7 @@ module Pod
84
84
  def generate_platform_import_header
85
85
  case platform.name
86
86
  when :ios then "#import <UIKit/UIKit.h>\n"
87
+ when :tvos then "#import <UIKit/UIKit.h>\n"
87
88
  when :osx then "#import <Cocoa/Cocoa.h>\n"
88
89
  else "#import <Foundation/Foundation.h>\n"
89
90
  end
@@ -60,6 +60,9 @@ module Pod
60
60
  'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) COCOAPODS=1',
61
61
  'FRAMEWORK_SEARCH_PATHS' => '$(inherited) ',
62
62
  }
63
+ if pod_targets.any?(&:uses_swift?)
64
+ config['EMBEDDED_CONTENT_CONTAINS_SWIFT'] = 'YES'
65
+ end
63
66
  @xcconfig = Xcodeproj::Config.new(config)
64
67
 
65
68
  @xcconfig.merge!(merged_user_target_xcconfigs)
@@ -47,7 +47,7 @@ module Pod
47
47
 
48
48
  config = {
49
49
  'OTHER_LDFLAGS' => XCConfigHelper.default_ld_flags(target),
50
- 'PODS_ROOT' => '${SRCROOT}',
50
+ 'PODS_ROOT' => '${SRCROOT}',
51
51
  'HEADER_SEARCH_PATHS' => XCConfigHelper.quote(search_paths),
52
52
  'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) COCOAPODS=1',
53
53
  'SKIP_INSTALL' => 'YES',
@@ -18,7 +18,7 @@ module Pod
18
18
  #
19
19
  def self.quote(strings, prefix = nil)
20
20
  prefix = "#{prefix} " if prefix
21
- strings.sort.map { |s| %W( #{prefix}"#{s}" ) }.join(' ')
21
+ strings.sort.map { |s| %W( #{prefix}"#{s}" ) }.join(' ')
22
22
  end
23
23
 
24
24
  # Return the default linker flags
@@ -74,7 +74,7 @@ module Pod
74
74
  xcconfig.libraries.merge(consumer.libraries)
75
75
  xcconfig.frameworks.merge(consumer.frameworks)
76
76
  xcconfig.weak_frameworks.merge(consumer.weak_frameworks)
77
- add_developers_frameworks_if_needed(xcconfig, consumer.platform_name)
77
+ add_developers_frameworks_if_needed(xcconfig)
78
78
  end
79
79
 
80
80
  # Configures the given Xcconfig with the build settings for the given
@@ -183,17 +183,12 @@ module Pod
183
183
  #
184
184
  # @return [void]
185
185
  #
186
- def self.add_developers_frameworks_if_needed(xcconfig, platform)
186
+ def self.add_developers_frameworks_if_needed(xcconfig)
187
187
  matched_frameworks = xcconfig.frameworks & %w(XCTest SenTestingKit)
188
188
  unless matched_frameworks.empty?
189
189
  search_paths = xcconfig.attributes['FRAMEWORK_SEARCH_PATHS'] ||= ''
190
190
  search_paths_to_add = []
191
191
  search_paths_to_add << '$(inherited)'
192
- if platform == :ios || platform == :watchos
193
- search_paths_to_add << '"$(SDKROOT)/Developer/Library/Frameworks"'
194
- else
195
- search_paths_to_add << '"$(DEVELOPER_LIBRARY_DIR)/Frameworks"'
196
- end
197
192
  frameworks_path = '"$(PLATFORM_DIR)/Developer/Library/Frameworks"'
198
193
  search_paths_to_add << frameworks_path
199
194
  search_paths_to_add.each do |search_path|
@@ -105,7 +105,7 @@ module Pod
105
105
  if registrations
106
106
  hooks = registrations[name]
107
107
  if hooks
108
- UI.message "- Running #{name.to_s.gsub('_', ' ')} hooks" do
108
+ UI.message "- Running #{name.to_s.tr('_', ' ')} hooks" do
109
109
  hooks.each do |hook|
110
110
  next if whitelisted_plugins && !whitelisted_plugins.key?(hook.plugin_name)
111
111
  UI.message "- #{hook.plugin_name || 'unknown plugin'} from " \
@@ -462,6 +462,16 @@ module Pod
462
462
  run_plugins_post_install_hooks
463
463
  warn_for_deprecations
464
464
  lock_pod_sources
465
+ print_post_install_message
466
+ end
467
+
468
+ def print_post_install_message
469
+ podfile_dependencies = podfile.dependencies.uniq.size
470
+ pods_installed = root_specs.size
471
+ UI.info('Pod installation complete! ' \
472
+ "There #{podfile_dependencies == 1 ? 'is' : 'are'} #{podfile_dependencies} " \
473
+ "#{'dependency'.pluralize(podfile_dependencies)} from the Podfile " \
474
+ "and #{pods_installed} total #{'pod'.pluralize(pods_installed)} installed.")
465
475
  end
466
476
 
467
477
  # Runs the registered callbacks for the plugins post install hooks.
@@ -569,10 +579,12 @@ module Pod
569
579
  osx_deployment_target = platforms.select { |p| p.name == :osx }.map(&:deployment_target).min
570
580
  ios_deployment_target = platforms.select { |p| p.name == :ios }.map(&:deployment_target).min
571
581
  watchos_deployment_target = platforms.select { |p| p.name == :watchos }.map(&:deployment_target).min
582
+ tvos_deployment_target = platforms.select { |p| p.name == :tvos }.map(&:deployment_target).min
572
583
  @pods_project.build_configurations.each do |build_configuration|
573
584
  build_configuration.build_settings['MACOSX_DEPLOYMENT_TARGET'] = osx_deployment_target.to_s if osx_deployment_target
574
585
  build_configuration.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = ios_deployment_target.to_s if ios_deployment_target
575
586
  build_configuration.build_settings['WATCHOS_DEPLOYMENT_TARGET'] = watchos_deployment_target.to_s if watchos_deployment_target
587
+ build_configuration.build_settings['TVOS_DEPLOYMENT_TARGET'] = tvos_deployment_target.to_s if tvos_deployment_target
576
588
  build_configuration.build_settings['STRIP_INSTALLED_PRODUCT'] = 'NO'
577
589
  build_configuration.build_settings['CLANG_ENABLE_OBJC_ARC'] = 'YES'
578
590
  end
@@ -732,7 +744,7 @@ module Pod
732
744
  # information in the lockfile.
733
745
  #
734
746
  def integrate_user_project
735
- UI.section "Integrating client #{'project'.pluralize(aggregate_targets.map(&:user_project_path).uniq.count) }" do
747
+ UI.section "Integrating client #{'project'.pluralize(aggregate_targets.map(&:user_project_path).uniq.count)}" do
736
748
  installation_root = config.installation_root
737
749
  integrator = UserProjectIntegrator.new(podfile, sandbox, installation_root, aggregate_targets)
738
750
  integrator.integrate!
@@ -255,7 +255,7 @@ module Pod
255
255
  target.client_root = config.installation_root
256
256
  target.user_target_uuids = []
257
257
  target.user_build_configurations = target_definition.build_configurations || { 'Release' => :release, 'Debug' => :debug }
258
- if target_definition.platform.name == :osx
258
+ if target_definition.platform && target_definition.platform.name == :osx
259
259
  target.archs = '$(ARCHS_STANDARD_64_BIT)'
260
260
  end
261
261
  end
@@ -292,9 +292,9 @@ module Pod
292
292
  pod_targets = distinct_targets.flat_map do |_, targets_by_distinctors|
293
293
  if targets_by_distinctors.count > 1
294
294
  # There are different sets of subspecs or the spec is used across different platforms
295
- targets_by_distinctors.map do |distinctor, target_definitions|
296
- specs, _ = *distinctor
297
- generate_pod_target(target_definitions, specs, :scoped => true)
295
+ targets_by_distinctors.flat_map do |distinctor, target_definitions|
296
+ specs, = *distinctor
297
+ generate_pod_target(target_definitions, specs).scoped
298
298
  end
299
299
  else
300
300
  (specs, _), target_definitions = targets_by_distinctors.first
@@ -317,7 +317,7 @@ module Pod
317
317
  pod_targets = specs_by_target.flat_map do |target_definition, specs|
318
318
  grouped_specs = specs.group_by.group_by(&:root).values.uniq
319
319
  grouped_specs.flat_map do |pod_specs|
320
- generate_pod_target([target_definition], pod_specs, :scoped => true)
320
+ generate_pod_target([target_definition], pod_specs).scoped
321
321
  end
322
322
  end
323
323
  pod_targets.each do |target|
@@ -364,13 +364,10 @@ module Pod
364
364
  # @param [Array<Specification>] specs
365
365
  # the specifications of an equal root.
366
366
  #
367
- # @param [Bool] scoped
368
- # whether the pod target should be scoped
369
- #
370
367
  # @return [PodTarget]
371
368
  #
372
- def generate_pod_target(target_definitions, pod_specs, scoped: false)
373
- pod_target = PodTarget.new(pod_specs, target_definitions, sandbox, scoped)
369
+ def generate_pod_target(target_definitions, pod_specs)
370
+ pod_target = PodTarget.new(pod_specs, target_definitions, sandbox)
374
371
 
375
372
  if config.integrate_targets?
376
373
  target_inspections = result.target_inspections.select { |t, _| target_definitions.include?(t) }.values
@@ -639,7 +636,7 @@ module Pod
639
636
  def verify_platforms_specified!
640
637
  unless config.integrate_targets?
641
638
  podfile.target_definition_list.each do |target_definition|
642
- unless target_definition.platform
639
+ if !target_definition.empty? && target_definition.platform.nil?
643
640
  raise Informative, 'It is necessary to specify the platform in the Podfile if not integrating.'
644
641
  end
645
642
  end
@@ -23,9 +23,9 @@ module Pod
23
23
  @unchanged = []
24
24
 
25
25
  if pods_by_state
26
- @added = pods_by_state[:added] || []
27
- @deleted = pods_by_state[:removed] || []
28
- @changed = pods_by_state[:changed] || []
26
+ @added = pods_by_state[:added] || []
27
+ @deleted = pods_by_state[:removed] || []
28
+ @changed = pods_by_state[:changed] || []
29
29
  @unchanged = pods_by_state[:unchanged] || []
30
30
  end
31
31
  end
@@ -51,10 +51,10 @@ module Pod
51
51
  # @return [void]
52
52
  #
53
53
  def print
54
- added .sort.each { |pod| UI.message('A'.green + " #{pod}", '', 2) }
55
- deleted .sort.each { |pod| UI.message('R'.red + " #{pod}", '', 2) }
54
+ added .sort.each { |pod| UI.message('A'.green + " #{pod}", '', 2) }
55
+ deleted .sort.each { |pod| UI.message('R'.red + " #{pod}", '', 2) }
56
56
  changed .sort.each { |pod| UI.message('M'.yellow + " #{pod}", '', 2) }
57
- unchanged.sort.each { |pod| UI.message('-' + " #{pod}", '', 2) }
57
+ unchanged.sort.each { |pod| UI.message('-' + " #{pod}", '', 2) }
58
58
  end
59
59
 
60
60
  # Adds the name of a Pod to the give state.
@@ -66,7 +66,7 @@ module Pod
66
66
  #
67
67
  attr_accessor :specs
68
68
 
69
- # @return [Symbol] The platform (either `:ios`, `:watchos` or `:osx`).
69
+ # @return [Symbol] The platform (either `:ios`, `:watchos`, `:tvos`, or `:osx`).
70
70
  #
71
71
  attr_accessor :platform_name
72
72
 
@@ -36,21 +36,16 @@ module Pod
36
36
 
37
37
  private
38
38
 
39
- # Adds the project/library and compatibility versions, which are only
40
- # applicable to dynamic libraries.
39
+ # Remove the default headers folder path settings for static library pod
40
+ # targets.
41
41
  #
42
42
  # @return [Hash{String => String}]
43
43
  #
44
44
  def custom_build_settings
45
45
  settings = super
46
- if target.requires_frameworks?
47
- version = target.root_spec.version
48
- project_version = [version.major, version.minor, version.patch].join('.')
49
- compatibility_version = version.major
50
- compatibility_version = project_version if compatibility_version < 1
51
- settings['CURRENT_PROJECT_VERSION'] = project_version
52
- settings['DYLIB_COMPATIBILITY_VERSION'] = compatibility_version.to_s
53
- settings['DYLIB_CURRENT_VERSION'] = '$(CURRENT_PROJECT_VERSION)'
46
+ unless target.requires_frameworks?
47
+ settings['PRIVATE_HEADERS_FOLDER_PATH'] = ''
48
+ settings['PUBLIC_HEADERS_FOLDER_PATH'] = ''
54
49
  end
55
50
  settings
56
51
  end
@@ -199,6 +194,7 @@ module Pod
199
194
  :ios => Version.new('6'),
200
195
  :osx => Version.new('10.8'),
201
196
  :watchos => Version.new('2.0'),
197
+ :tvos => Version.new('9.0'),
202
198
  }
203
199
 
204
200
  # Returns the compiler flags for the source files of the given specification.
@@ -227,7 +227,7 @@ module Pod
227
227
  native_targets_to_integrate.each do |native_target|
228
228
  phase = create_or_update_build_phase(native_target, phase_name)
229
229
  native_target.build_phases.unshift(phase).uniq!
230
- phase.shell_script = <<-EOS.strip_heredoc
230
+ phase.shell_script = <<-SH.strip_heredoc
231
231
  diff "${PODS_ROOT}/../Podfile.lock" "${PODS_ROOT}/Manifest.lock" > /dev/null
232
232
  if [[ $? != 0 ]] ; then
233
233
  cat << EOM
@@ -235,7 +235,7 @@ module Pod
235
235
  EOM
236
236
  exit 1
237
237
  fi
238
- EOS
238
+ SH
239
239
  end
240
240
  end
241
241
 
@@ -174,7 +174,7 @@ module Pod
174
174
  #
175
175
  def requirement_satisfied_by?(requirement, activated, spec)
176
176
  existing_vertices = activated.vertices.values.select do |v|
177
- Specification.root_name(v.name) == requirement.root_name
177
+ Specification.root_name(v.name) == requirement.root_name
178
178
  end
179
179
  existing = existing_vertices.map(&:payload).compact.first
180
180
  requirement_satisfied =
@@ -383,6 +383,21 @@ module Pod
383
383
  'version requirement to your Podfile ' \
384
384
  "(e.g. `pod '#{name}', '#{lockfile_reqs.map(&:requirement).join("', '")}'`) " \
385
385
  "or revert to a stable version by running `pod update #{name}`."
386
+ elsif (conflict.possibility && conflict.possibility.version.prerelease?) &&
387
+ (conflict.requirement && !(
388
+ conflict.requirement.prerelease? ||
389
+ conflict.requirement.external_source ||
390
+ conflict.requirement.head?)
391
+ )
392
+ # Conflict was caused by not specifying an explicit version for the requirement #[name],
393
+ # and there is no available stable version satisfying constraints for the requirement.
394
+ message = "There are only pre-release versions available satisfying the following requirements:\n"
395
+ conflict.requirements.values.flatten.each do |r|
396
+ unless search_for(r).empty?
397
+ message << "\n\t'#{name}', '#{r.requirement}'\n"
398
+ end
399
+ end
400
+ message << "\nYou should explicitly specify the version in order to install a pre-release version"
386
401
  elsif !conflict.existing
387
402
  conflict.requirements.values.flatten.each do |r|
388
403
  unless search_for(r).empty?
@@ -8,7 +8,7 @@ module Pod
8
8
  #
9
9
  class FileAccessor
10
10
  HEADER_EXTENSIONS = Xcodeproj::Constants::HEADER_FILES_EXTENSIONS
11
- SOURCE_FILE_EXTENSIONS = (%w(.m .mm .c .cc .cxx .cpp .c++ .swift) + HEADER_EXTENSIONS).uniq.freeze
11
+ SOURCE_FILE_EXTENSIONS = (%w(.m .mm .i .c .cc .cxx .cpp .c++ .swift) + HEADER_EXTENSIONS).uniq.freeze
12
12
 
13
13
  GLOB_PATTERNS = {
14
14
  :readme => 'readme{*,.*}'.freeze,
@@ -49,7 +49,7 @@ module Pod
49
49
  end
50
50
  root_length = root.to_s.length + 1
51
51
  escaped_root = escape_path_for_glob(root)
52
- paths = Dir.glob(escaped_root + '**/*', File::FNM_DOTMATCH)
52
+ paths = Dir.glob(escaped_root + '**/*', File::FNM_DOTMATCH)
53
53
  absolute_dirs = paths.select { |path| File.directory?(path) }
54
54
  relative_dirs = absolute_dirs.map { |p| p[root_length..-1] }
55
55
  absolute_paths = paths.reject { |p| p == "#{root}/." || p == "#{root}/.." }
@@ -252,7 +252,8 @@ module Pod
252
252
  def check_version_information(dir)
253
253
  versions = version_information(dir)
254
254
  unless repo_compatible?(dir)
255
- min, max = versions['min'], versions['max']
255
+ min = versions['min']
256
+ max = versions['max']
256
257
  version_msg = (min == max) ? min : "#{min} - #{max}"
257
258
  raise Informative, "The `#{dir.basename}` repo requires " \
258
259
  "CocoaPods #{version_msg} (currently using #{Pod::VERSION})\n".red +
@@ -293,7 +294,8 @@ module Pod
293
294
  def repo_compatible?(dir)
294
295
  versions = version_information(dir)
295
296
 
296
- min, max = versions['min'], versions['max']
297
+ min = versions['min']
298
+ max = versions['max']
297
299
  bin_version = Gem::Version.new(Pod::VERSION)
298
300
  supports_min = !min || bin_version >= Gem::Version.new(min)
299
301
  supports_max = !max || bin_version <= Gem::Version.new(max)
@@ -329,7 +331,7 @@ module Pod
329
331
  #
330
332
  def version_information(dir)
331
333
  require 'yaml'
332
- yaml_file = dir + 'CocoaPods-version.yml'
334
+ yaml_file = dir + 'CocoaPods-version.yml'
333
335
  return {} unless yaml_file.exist?
334
336
  begin
335
337
  YAMLHelper.load_file(yaml_file)
@@ -66,7 +66,7 @@ module Pod
66
66
  target.user_build_configurations = user_build_configurations
67
67
  target.native_target = native_target
68
68
  target.archs = archs
69
- target.dependent_targets = dependent_targets.flat_map(&:scoped)
69
+ target.dependent_targets = dependent_targets.flat_map(&:scoped).select { |pt| pt.target_definitions == [target_definition] }
70
70
  end
71
71
  end
72
72
  end
@@ -7,7 +7,7 @@ module Pod
7
7
  module UserInterface
8
8
  require 'colored'
9
9
 
10
- @title_colors = %w( yellow green )
10
+ @title_colors = %w( yellow green )
11
11
  @title_level = 0
12
12
  @indentation_level = 2
13
13
  @treat_titles_as_messages = false
@@ -298,14 +298,14 @@ module Pod
298
298
  #
299
299
  def choose_from_array(array, message)
300
300
  array.each_with_index do |item, index|
301
- UI.puts "#{ index + 1 }: #{ item }"
301
+ UI.puts "#{index + 1}: #{item}"
302
302
  end
303
303
 
304
304
  UI.puts message
305
305
 
306
306
  index = UI.gets.chomp.to_i - 1
307
307
  if index < 0 || index > array.count - 1
308
- raise Informative, "#{ index + 1 } is invalid [1-#{ array.count }]"
308
+ raise Informative, "#{index + 1} is invalid [1-#{array.count}]"
309
309
  else
310
310
  index
311
311
  end
@@ -94,6 +94,8 @@ module Pod
94
94
  platform_message = '[OSX] '
95
95
  elsif result.platforms == [:watchos]
96
96
  platform_message = '[watchOS] '
97
+ elsif result.platforms == [:tvos]
98
+ platform_message = '[tvOS] '
97
99
  end
98
100
 
99
101
  subspecs_message = ''
@@ -609,7 +611,16 @@ module Pod
609
611
  #
610
612
  def xcodebuild
611
613
  command = 'xcodebuild clean build -target Pods'
612
- command << ' CODE_SIGN_IDENTITY=- -sdk iphonesimulator' if consumer.platform_name == :ios
614
+
615
+ case consumer.platform_name
616
+ when :ios
617
+ command << ' CODE_SIGN_IDENTITY=- -sdk iphonesimulator'
618
+ when :watchos
619
+ command << ' CODE_SIGN_IDENTITY=- -sdk watchsimulator'
620
+ when :tvos
621
+ command << ' CODE_SIGN_IDENTITY=- -sdk appletvsimulator'
622
+ end
623
+
613
624
  output, status = _xcodebuild "#{command} 2>&1"
614
625
 
615
626
  unless status.success?
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cocoapods
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.39.0.beta.4
4
+ version: 0.39.0.beta.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eloy Duran
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2015-09-01 00:00:00.000000000 Z
14
+ date: 2015-10-01 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: cocoapods-core
@@ -19,14 +19,14 @@ dependencies:
19
19
  requirements:
20
20
  - - '='
21
21
  - !ruby/object:Gem::Version
22
- version: 0.39.0.beta.4
22
+ version: 0.39.0.beta.5
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
26
26
  requirements:
27
27
  - - '='
28
28
  - !ruby/object:Gem::Version
29
- version: 0.39.0.beta.4
29
+ version: 0.39.0.beta.5
30
30
  - !ruby/object:Gem::Dependency
31
31
  name: claide
32
32
  requirement: !ruby/object:Gem::Requirement
@@ -47,14 +47,14 @@ dependencies:
47
47
  requirements:
48
48
  - - ~>
49
49
  - !ruby/object:Gem::Version
50
- version: 0.27.2
50
+ version: 0.28.0
51
51
  type: :runtime
52
52
  prerelease: false
53
53
  version_requirements: !ruby/object:Gem::Requirement
54
54
  requirements:
55
55
  - - ~>
56
56
  - !ruby/object:Gem::Version
57
- version: 0.27.2
57
+ version: 0.28.0
58
58
  - !ruby/object:Gem::Dependency
59
59
  name: cocoapods-downloader
60
60
  requirement: !ruby/object:Gem::Requirement
@@ -83,6 +83,20 @@ dependencies:
83
83
  - - ~>
84
84
  - !ruby/object:Gem::Version
85
85
  version: 0.4.2
86
+ - !ruby/object:Gem::Dependency
87
+ name: cocoapods-search
88
+ requirement: !ruby/object:Gem::Requirement
89
+ requirements:
90
+ - - ~>
91
+ - !ruby/object:Gem::Version
92
+ version: 0.1.0
93
+ type: :runtime
94
+ prerelease: false
95
+ version_requirements: !ruby/object:Gem::Requirement
96
+ requirements:
97
+ - - ~>
98
+ - !ruby/object:Gem::Version
99
+ version: 0.1.0
86
100
  - !ruby/object:Gem::Dependency
87
101
  name: cocoapods-stats
88
102
  requirement: !ruby/object:Gem::Requirement
@@ -173,14 +187,14 @@ dependencies:
173
187
  requirements:
174
188
  - - '>='
175
189
  - !ruby/object:Gem::Version
176
- version: 3.2.15
190
+ version: 4.0.2
177
191
  type: :runtime
178
192
  prerelease: false
179
193
  version_requirements: !ruby/object:Gem::Requirement
180
194
  requirements:
181
195
  - - '>='
182
196
  - !ruby/object:Gem::Version
183
- version: 3.2.15
197
+ version: 4.0.2
184
198
  - !ruby/object:Gem::Dependency
185
199
  name: nap
186
200
  requirement: !ruby/object:Gem::Requirement
@@ -254,52 +268,45 @@ executables:
254
268
  extensions: []
255
269
  extra_rdoc_files: []
256
270
  files:
257
- - CHANGELOG.md
258
- - LICENSE
259
- - README.md
260
- - bin/pod
261
- - bin/sandbox-pod
262
- - lib/cocoapods.rb
263
- - lib/cocoapods/command.rb
264
- - lib/cocoapods/command/cache.rb
265
271
  - lib/cocoapods/command/cache/clean.rb
266
272
  - lib/cocoapods/command/cache/list.rb
273
+ - lib/cocoapods/command/cache.rb
267
274
  - lib/cocoapods/command/init.rb
268
275
  - lib/cocoapods/command/inter_process_communication.rb
269
276
  - lib/cocoapods/command/lib.rb
270
277
  - lib/cocoapods/command/list.rb
271
278
  - lib/cocoapods/command/outdated.rb
272
279
  - lib/cocoapods/command/project.rb
273
- - lib/cocoapods/command/repo.rb
274
280
  - lib/cocoapods/command/repo/add.rb
275
281
  - lib/cocoapods/command/repo/lint.rb
276
282
  - lib/cocoapods/command/repo/list.rb
277
283
  - lib/cocoapods/command/repo/push.rb
278
284
  - lib/cocoapods/command/repo/remove.rb
279
285
  - lib/cocoapods/command/repo/update.rb
280
- - lib/cocoapods/command/search.rb
286
+ - lib/cocoapods/command/repo.rb
281
287
  - lib/cocoapods/command/setup.rb
282
- - lib/cocoapods/command/spec.rb
283
288
  - lib/cocoapods/command/spec/cat.rb
284
289
  - lib/cocoapods/command/spec/create.rb
285
290
  - lib/cocoapods/command/spec/edit.rb
286
291
  - lib/cocoapods/command/spec/lint.rb
287
292
  - lib/cocoapods/command/spec/which.rb
293
+ - lib/cocoapods/command/spec.rb
294
+ - lib/cocoapods/command.rb
288
295
  - lib/cocoapods/config.rb
289
- - lib/cocoapods/downloader.rb
290
296
  - lib/cocoapods/downloader/cache.rb
291
297
  - lib/cocoapods/downloader/request.rb
292
298
  - lib/cocoapods/downloader/response.rb
299
+ - lib/cocoapods/downloader.rb
293
300
  - lib/cocoapods/executable.rb
294
- - lib/cocoapods/external_sources.rb
295
301
  - lib/cocoapods/external_sources/abstract_external_source.rb
296
302
  - lib/cocoapods/external_sources/downloader_source.rb
297
303
  - lib/cocoapods/external_sources/path_source.rb
298
304
  - lib/cocoapods/external_sources/podspec_source.rb
305
+ - lib/cocoapods/external_sources.rb
299
306
  - lib/cocoapods/gem_version.rb
300
- - lib/cocoapods/generator/acknowledgements.rb
301
307
  - lib/cocoapods/generator/acknowledgements/markdown.rb
302
308
  - lib/cocoapods/generator/acknowledgements/plist.rb
309
+ - lib/cocoapods/generator/acknowledgements.rb
303
310
  - lib/cocoapods/generator/bridge_support.rb
304
311
  - lib/cocoapods/generator/copy_resources_script.rb
305
312
  - lib/cocoapods/generator/dummy_source.rb
@@ -309,19 +316,18 @@ files:
309
316
  - lib/cocoapods/generator/module_map.rb
310
317
  - lib/cocoapods/generator/prefix_header.rb
311
318
  - lib/cocoapods/generator/umbrella_header.rb
312
- - lib/cocoapods/generator/xcconfig.rb
313
319
  - lib/cocoapods/generator/xcconfig/aggregate_xcconfig.rb
314
320
  - lib/cocoapods/generator/xcconfig/pod_xcconfig.rb
315
321
  - lib/cocoapods/generator/xcconfig/xcconfig_helper.rb
322
+ - lib/cocoapods/generator/xcconfig.rb
316
323
  - lib/cocoapods/hooks_manager.rb
317
- - lib/cocoapods/installer.rb
318
- - lib/cocoapods/installer/analyzer.rb
319
324
  - lib/cocoapods/installer/analyzer/analysis_result.rb
320
325
  - lib/cocoapods/installer/analyzer/locking_dependency_analyzer.rb
321
326
  - lib/cocoapods/installer/analyzer/sandbox_analyzer.rb
322
327
  - lib/cocoapods/installer/analyzer/specs_state.rb
323
328
  - lib/cocoapods/installer/analyzer/target_inspection_result.rb
324
329
  - lib/cocoapods/installer/analyzer/target_inspector.rb
330
+ - lib/cocoapods/installer/analyzer.rb
325
331
  - lib/cocoapods/installer/file_references_installer.rb
326
332
  - lib/cocoapods/installer/migrator.rb
327
333
  - lib/cocoapods/installer/pod_source_installer.rb
@@ -330,29 +336,36 @@ files:
330
336
  - lib/cocoapods/installer/post_install_hooks_context.rb
331
337
  - lib/cocoapods/installer/pre_install_hooks_context.rb
332
338
  - lib/cocoapods/installer/source_provider_hooks_context.rb
333
- - lib/cocoapods/installer/target_installer.rb
334
339
  - lib/cocoapods/installer/target_installer/aggregate_target_installer.rb
335
340
  - lib/cocoapods/installer/target_installer/pod_target_installer.rb
336
- - lib/cocoapods/installer/user_project_integrator.rb
337
- - lib/cocoapods/installer/user_project_integrator/target_integrator.rb
341
+ - lib/cocoapods/installer/target_installer.rb
338
342
  - lib/cocoapods/installer/user_project_integrator/target_integrator/xcconfig_integrator.rb
343
+ - lib/cocoapods/installer/user_project_integrator/target_integrator.rb
344
+ - lib/cocoapods/installer/user_project_integrator.rb
345
+ - lib/cocoapods/installer.rb
339
346
  - lib/cocoapods/open_uri.rb
340
347
  - lib/cocoapods/project.rb
341
- - lib/cocoapods/resolver.rb
342
348
  - lib/cocoapods/resolver/lazy_specification.rb
343
- - lib/cocoapods/sandbox.rb
349
+ - lib/cocoapods/resolver.rb
344
350
  - lib/cocoapods/sandbox/file_accessor.rb
345
351
  - lib/cocoapods/sandbox/headers_store.rb
346
352
  - lib/cocoapods/sandbox/path_list.rb
347
353
  - lib/cocoapods/sandbox/pod_dir_cleaner.rb
348
354
  - lib/cocoapods/sandbox/podspec_finder.rb
355
+ - lib/cocoapods/sandbox.rb
349
356
  - lib/cocoapods/sources_manager.rb
350
- - lib/cocoapods/target.rb
351
357
  - lib/cocoapods/target/aggregate_target.rb
352
358
  - lib/cocoapods/target/pod_target.rb
353
- - lib/cocoapods/user_interface.rb
359
+ - lib/cocoapods/target.rb
354
360
  - lib/cocoapods/user_interface/error_report.rb
361
+ - lib/cocoapods/user_interface.rb
355
362
  - lib/cocoapods/validator.rb
363
+ - lib/cocoapods.rb
364
+ - bin/pod
365
+ - bin/sandbox-pod
366
+ - README.md
367
+ - LICENSE
368
+ - CHANGELOG.md
356
369
  homepage: https://github.com/CocoaPods/CocoaPods
357
370
  licenses:
358
371
  - MIT
@@ -373,7 +386,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
373
386
  version: '0'
374
387
  requirements: []
375
388
  rubyforge_project:
376
- rubygems_version: 2.4.8
389
+ rubygems_version: 2.0.14.1
377
390
  signing_key:
378
391
  specification_version: 3
379
392
  summary: The Cocoa library package manager.
@@ -1,101 +0,0 @@
1
- module Pod
2
- class Command
3
- class Search < Command
4
- self.summary = 'Searches for pods'
5
-
6
- self.description = <<-DESC
7
- Searches for pods, ignoring case, whose name matches `QUERY`. If the
8
- `--full` option is specified, this will also search in the summary and
9
- description of the pods.
10
- DESC
11
-
12
- self.arguments = [
13
- CLAide::Argument.new('QUERY', true),
14
- ]
15
-
16
- def self.options
17
- [
18
- ['--regex', 'Interpret the `QUERY` as a regular expression'],
19
- ['--full', 'Search by name, summary, and description'],
20
- ['--stats', 'Show additional stats (like GitHub watchers and forks)'],
21
- ['--ios', 'Restricts the search to Pods supported on iOS'],
22
- ['--osx', 'Restricts the search to Pods supported on OS X'],
23
- ['--web', 'Searches on cocoapods.org'],
24
- ].concat(super.reject { |option, _| option == '--silent' })
25
- end
26
-
27
- def initialize(argv)
28
- @use_regex = argv.flag?('regex')
29
- @full_text_search = argv.flag?('full')
30
- @stats = argv.flag?('stats')
31
- @supported_on_ios = argv.flag?('ios')
32
- @supported_on_osx = argv.flag?('osx')
33
- @web = argv.flag?('web')
34
- @query = argv.arguments! unless argv.arguments.empty?
35
- config.silent = false
36
- super
37
- end
38
-
39
- def validate!
40
- super
41
- help! 'A search query is required.' unless @query
42
-
43
- unless @web || !@use_regex
44
- begin
45
- /#{@query.join(' ').strip}/
46
- rescue RegexpError
47
- help! 'A valid regular expression is required.'
48
- end
49
- end
50
- end
51
-
52
- def run
53
- ensure_master_spec_repo_exists!
54
- if @web
55
- web_search
56
- else
57
- local_search
58
- end
59
- end
60
-
61
- extend Executable
62
- executable :open
63
-
64
- def web_search
65
- query_parameter = [
66
- ('on:osx' if @supported_on_osx),
67
- ('on:ios' if @supported_on_ios),
68
- @query,
69
- ].compact.flatten.join(' ')
70
- url = "http://cocoapods.org/?q=#{CGI.escape(query_parameter).gsub('+', '%20')}"
71
- UI.puts("Opening #{url}")
72
- open!(url)
73
- end
74
-
75
- def local_search
76
- query_regex = @query.join(' ').strip
77
- query_regex = Regexp.escape(query_regex) unless @use_regex
78
-
79
- sets = SourcesManager.search_by_name(query_regex, @full_text_search)
80
- if @supported_on_ios
81
- sets.reject! { |set| !set.specification.available_platforms.map(&:name).include?(:ios) }
82
- end
83
- if @supported_on_osx
84
- sets.reject! { |set| !set.specification.available_platforms.map(&:name).include?(:osx) }
85
- end
86
-
87
- sets.each do |set|
88
- begin
89
- if @stats
90
- UI.pod(set, :stats)
91
- else
92
- UI.pod(set, :normal)
93
- end
94
- rescue DSLError
95
- UI.warn "Skipping `#{set.name}` because the podspec contains errors."
96
- end
97
- end
98
- end
99
- end
100
- end
101
- end