cocoapods-packager 1.0.2 → 1.1.0

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ded7fd8c41f11780560b66ca3ee8a8c98e76fc38
4
- data.tar.gz: cb2268abe296f659ca6e5c0ad36199d7309cef55
3
+ metadata.gz: f68350cb77545ef11604ac7139398932e10ca6f8
4
+ data.tar.gz: 747890a043aeb9cdefb008c0e1c6142c798991fd
5
5
  SHA512:
6
- metadata.gz: f834c2bdebc968c40451c9cf362cec3f2814dc96ff00ca79a6e9cb7f63e62e71654196dddca2d5fd868441839b9c8b7153064662052ca5401531fcf60f9cd5f0
7
- data.tar.gz: a390c36b4fa38056ae7d8d844c5dd5b31245ab83b6aea3ed5cd3b8f73487962af158a163f08e5e75f6bf7b248ceab94078c0ad5a13dc4de00e0e17250f07fb39
6
+ metadata.gz: 33e98e575824bc64a7b46faaa6b73e5cf0cb54f96a0ea1efadbb6cfa5b9d550e57ec82e27a02d334ed9fe2d47006e5dcab06077175144106c4dffac01edfaba9
7
+ data.tar.gz: c7257bec6e11d1274f0b2e8319129d1e0ab17eb44a2f9121fded44b6b2b87ee093ae3f2881288ed8e73ec07a4f95d0536b9e6f9bfa762171f8e2ce22cf5ba447
data/Gemfile CHANGED
@@ -3,7 +3,7 @@ source 'https://rubygems.org'
3
3
  gemspec
4
4
 
5
5
  group :development do
6
- gem 'cocoapods', '>= 0.33.0'
6
+ gem 'cocoapods', '>= 0.34.0'
7
7
  gem 'bacon'
8
8
  gem 'mocha-on-bacon'
9
9
  gem 'mocha', '~> 0.11.4'
data/Gemfile.lock CHANGED
@@ -9,43 +9,44 @@ GIT
9
9
  PATH
10
10
  remote: .
11
11
  specs:
12
- cocoapods-packager (1.0.2)
12
+ cocoapods-packager (1.1.0)
13
13
 
14
14
  GEM
15
15
  remote: https://rubygems.org/
16
16
  specs:
17
+ CFPropertyList (2.2.8)
17
18
  activesupport (3.2.19)
18
19
  i18n (~> 0.6, >= 0.6.4)
19
20
  multi_json (~> 1.0)
20
21
  bacon (1.2.0)
21
- claide (0.6.1)
22
- cocoapods (0.33.1)
22
+ claide (0.7.0)
23
+ cocoapods (0.34.0)
23
24
  activesupport (>= 3.2.15, < 4)
24
- claide (~> 0.6.1)
25
- cocoapods-core (= 0.33.1)
26
- cocoapods-downloader (~> 0.6.1)
27
- cocoapods-plugins (~> 0.2.0)
28
- cocoapods-trunk (~> 0.1.1)
29
- cocoapods-try (~> 0.3.0)
25
+ claide (~> 0.7.0)
26
+ cocoapods-core (= 0.34.0)
27
+ cocoapods-downloader (~> 0.7.0)
28
+ cocoapods-plugins (~> 0.3.1)
29
+ cocoapods-trunk (~> 0.2.0)
30
+ cocoapods-try (~> 0.4.0)
30
31
  colored (~> 1.2)
31
32
  escape (~> 0.0.4)
32
33
  json_pure (~> 1.8)
33
- nap (~> 0.7)
34
+ nap (~> 0.8)
34
35
  open4 (~> 1.3)
35
- xcodeproj (~> 0.17.0)
36
- cocoapods-core (0.33.1)
36
+ xcodeproj (~> 0.19.2)
37
+ cocoapods-core (0.34.0)
37
38
  activesupport (>= 3.2.15)
38
39
  fuzzy_match (~> 2.0.4)
39
40
  json_pure (~> 1.8)
40
- nap (~> 0.5)
41
- cocoapods-downloader (0.6.1)
42
- cocoapods-plugins (0.2.0)
41
+ nap (~> 0.8.0)
42
+ cocoapods-downloader (0.7.0)
43
+ cocoapods-plugins (0.3.1)
43
44
  nap
44
- cocoapods-trunk (0.1.4)
45
+ cocoapods-trunk (0.2.0)
45
46
  json_pure (~> 1.8)
46
- nap (>= 0.6)
47
+ nap (>= 0.8)
47
48
  netrc
48
- cocoapods-try (0.3.0)
49
+ cocoapods-try (0.4.0)
49
50
  colored (1.2)
50
51
  coveralls (0.7.1)
51
52
  multi_json (~> 1.3)
@@ -81,7 +82,8 @@ GEM
81
82
  tins (~> 1.0)
82
83
  thor (0.19.1)
83
84
  tins (1.3.3)
84
- xcodeproj (0.17.0)
85
+ xcodeproj (0.19.2)
86
+ CFPropertyList (~> 2.2)
85
87
  activesupport (~> 3.0)
86
88
  colored (~> 1.2)
87
89
 
@@ -91,7 +93,7 @@ PLATFORMS
91
93
  DEPENDENCIES
92
94
  bacon
93
95
  bundler (~> 1.3)
94
- cocoapods (>= 0.33.0)
96
+ cocoapods (>= 0.34.0)
95
97
  cocoapods-packager!
96
98
  coveralls
97
99
  mocha (~> 0.11.4)
@@ -9,7 +9,7 @@ module Symbols
9
9
  #
10
10
  def mangle_for_pod_dependencies(pod_name, sandbox_root)
11
11
  pod_libs = Dir.glob("#{sandbox_root}/build/libPods-*.a").select do
12
- |file| file !~ /#{pod_name}/
12
+ |file| file !~ /libPods-#{pod_name}.a$/
13
13
  end
14
14
 
15
15
  dummy_alias = alias_symbol "PodsDummy_Pods_#{pod_name}", pod_name
@@ -9,7 +9,9 @@ module Pod
9
9
  @spec.name,
10
10
  platform_name,
11
11
  @spec.deployment_target(platform_name),
12
- @subspecs)
12
+ @subspecs,
13
+ @spec_sources,
14
+ )
13
15
 
14
16
  sandbox = Sandbox.new(config.sandbox_root)
15
17
  installer = Installer.new(sandbox, podfile)
@@ -18,8 +20,9 @@ module Pod
18
20
  sandbox
19
21
  end
20
22
 
21
- def podfile_from_spec(path, spec_name, platform_name, deployment_target, subspecs)
23
+ def podfile_from_spec(path, spec_name, platform_name, deployment_target, subspecs, sources)
22
24
  Pod::Podfile.new do
25
+ sources.each { |s| source s }
23
26
  platform(platform_name, deployment_target)
24
27
  if path
25
28
  if subspecs
@@ -1,5 +1,5 @@
1
1
  module Pod
2
2
  module Packager
3
- VERSION = '1.0.2'
3
+ VERSION = '1.1.0'
4
4
  end
5
5
  end
@@ -4,7 +4,10 @@ module Pod
4
4
  class Command
5
5
  class Package < Command
6
6
  self.summary = 'Package a podspec into a static library.'
7
- self.arguments = [['NAME', :required], ['SOURCE']]
7
+ self.arguments = [
8
+ CLAide::Argument.new('NAME', true),
9
+ CLAide::Argument.new('SOURCE', false),
10
+ ]
8
11
 
9
12
  def self.options
10
13
  [
@@ -12,7 +15,9 @@ module Pod
12
15
  ['--no-mangle', 'Do not mangle symbols of depedendant Pods.'],
13
16
  ['--embedded', 'Generate embedded frameworks.'],
14
17
  ['--library', 'Generate static libraries.'],
15
- ['--subspecs', 'Only include the given subspecs']
18
+ ['--subspecs', 'Only include the given subspecs'],
19
+ ['--spec-sources=private,https://github.com/CocoaPods/Specs.git', 'The sources to pull dependant ' \
20
+ 'pods from (defaults to https://github.com/CocoaPods/Specs.git)'],
16
21
  ]
17
22
  end
18
23
 
@@ -23,6 +28,7 @@ module Pod
23
28
  @mangle = argv.flag?('mangle', true)
24
29
  @name = argv.shift_argument
25
30
  @source = argv.shift_argument
31
+ @spec_sources = argv.option('spec-sources', 'https://github.com/CocoaPods/Specs.git').split(',')
26
32
 
27
33
  subspecs = argv.option('subspecs')
28
34
  @subspecs = subspecs.split(',') unless subspecs.nil?
@@ -7,6 +7,7 @@ module Pod
7
7
  Dir.glob("KFData-*").each { |dir| Pathname.new(dir).rmtree }
8
8
  Dir.glob("NikeKit-*").each { |dir| Pathname.new(dir).rmtree }
9
9
  Dir.glob("foo-bar-*").each { |dir| Pathname.new(dir).rmtree }
10
+ Dir.glob("a-*").each { |dir| Pathname.new(dir).rmtree }
10
11
  end
11
12
 
12
13
  it 'registers itself' do
@@ -41,6 +42,18 @@ module Pod
41
42
  BBUNikePlusTag }
42
43
  end
43
44
 
45
+ it "mangles symbols if the Pod has dependencies regardless of name" do
46
+ SourcesManager.stubs(:search).returns(nil)
47
+
48
+ command = Command.parse(%w{ package spec/fixtures/a.podspec })
49
+ command.run
50
+
51
+ lib = Dir.glob("a-*/ios/a.framework/a").first
52
+ symbols = Symbols.symbols_from_library(lib).uniq.sort.reject { |e| e =~ /Poda/ }
53
+ symbols.should == %w{ BBUNikePlusActivity BBUNikePlusSessionManager
54
+ BBUNikePlusTag }
55
+ end
56
+
44
57
  it "does not mangle symbols if option --no-mangle is specified" do
45
58
  SourcesManager.stubs(:search).returns(nil)
46
59
 
@@ -1,3 +1,5 @@
1
+ source 'https://github.com/CocoaPods/Specs.git'
2
+
1
3
  platform :ios, "6.0"
2
4
 
3
5
  target "PackagerTest" do
@@ -27,4 +27,4 @@ DEPENDENCIES:
27
27
  SPEC CHECKSUMS:
28
28
  AFNetworking: 6d7b76aa5d04c8c37daad3eef4b7e3f2a7620da3
29
29
 
30
- COCOAPODS: 0.33.1
30
+ COCOAPODS: 0.34.0
@@ -0,0 +1,19 @@
1
+ Pod::Spec.new do |s|
2
+ s.name = 'a'
3
+ s.version = '0.0.1'
4
+ s.summary = 'Objective-C implementation of the Nike+ API.'
5
+ s.homepage = 'https://github.com/neonichu/NikeKit'
6
+ s.license = {:type => 'MIT', :file => 'LICENSE'}
7
+ s.authors = { 'Boris Bügling' => 'http://buegling.com' }
8
+ s.source = { :git => 'https://github.com/neonichu/NikeKit.git', :tag => s.version.to_s }
9
+ s.platform = :ios, '6.0'
10
+
11
+ s.public_header_files = '*.h'
12
+ s.source_files = '*.{h,m}'
13
+ s.frameworks = 'Foundation'
14
+ s.requires_arc = true
15
+
16
+ s.dependency 'AFNetworking'
17
+ s.dependency 'ISO8601DateFormatter'
18
+ s.dependency 'KZPropertyMapper'
19
+ end
@@ -0,0 +1,27 @@
1
+ require File.expand_path('../../spec_helper', __FILE__)
2
+
3
+ module Pod
4
+ describe Command::Package do
5
+ it "uses additional spec repos passed on the command line" do
6
+ SourcesManager.stubs(:search).returns(nil)
7
+ nil::NilClass.any_instance.stubs(:install!)
8
+ Installer.expects(:new).with {
9
+ |sandbox, podfile| podfile.sources == ['foo', 'bar']
10
+ }
11
+
12
+ command = Command.parse(%w{ package spec/fixtures/KFData.podspec --spec-sources=foo,bar})
13
+ command.send(:install_pod, :osx)
14
+ end
15
+
16
+ it "uses only the master repo if no spec repos were passed" do
17
+ SourcesManager.stubs(:search).returns(nil)
18
+ nil::NilClass.any_instance.stubs(:install!)
19
+ Installer.expects(:new).with {
20
+ |sandbox, podfile| podfile.sources == ['https://github.com/CocoaPods/Specs.git']
21
+ }
22
+
23
+ command = Command.parse(%w{ package spec/fixtures/KFData.podspec })
24
+ command.send(:install_pod, :osx)
25
+ end
26
+ end
27
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cocoapods-packager
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kyle Fuller
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-09-20 00:00:00.000000000 Z
12
+ date: 2014-09-26 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler
@@ -92,9 +92,11 @@ files:
92
92
  - spec/fixtures/PackagerTest/PackagerTestTests/en.lproj/InfoPlist.strings
93
93
  - spec/fixtures/PackagerTest/Podfile
94
94
  - spec/fixtures/PackagerTest/Podfile.lock
95
+ - spec/fixtures/a.podspec
95
96
  - spec/fixtures/foo-bar.podspec
96
97
  - spec/fixtures/layer-client-messaging-schema.podspec
97
98
  - spec/integration/project_spec.rb
99
+ - spec/pod/utils_spec.rb
98
100
  - spec/spec_helper.rb
99
101
  - spec/specification/builder_spec.rb
100
102
  homepage: https://github.com/CocoaPods/cocoapods-packager
@@ -148,9 +150,11 @@ test_files:
148
150
  - spec/fixtures/PackagerTest/PackagerTestTests/en.lproj/InfoPlist.strings
149
151
  - spec/fixtures/PackagerTest/Podfile
150
152
  - spec/fixtures/PackagerTest/Podfile.lock
153
+ - spec/fixtures/a.podspec
151
154
  - spec/fixtures/foo-bar.podspec
152
155
  - spec/fixtures/layer-client-messaging-schema.podspec
153
156
  - spec/integration/project_spec.rb
157
+ - spec/pod/utils_spec.rb
154
158
  - spec/spec_helper.rb
155
159
  - spec/specification/builder_spec.rb
156
160
  has_rdoc: