cocoapods-store 0.0.1
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 +7 -0
- data/.gitignore +3 -0
- data/Gemfile +13 -0
- data/Gemfile.lock +103 -0
- data/LICENSE.txt +22 -0
- data/README.md +52 -0
- data/Rakefile +13 -0
- data/cocoapods-store.gemspec +25 -0
- data/lib/cocoapods-store.rb +1 -0
- data/lib/cocoapods-store/command.rb +1 -0
- data/lib/cocoapods-store/command/store.rb +88 -0
- data/lib/cocoapods-store/command/store/pull.rb +76 -0
- data/lib/cocoapods-store/command/store/push.rb +96 -0
- data/lib/cocoapods-store/gem_version.rb +3 -0
- data/lib/cocoapods_plugin.rb +1 -0
- data/spec/command/store_spec.rb +12 -0
- data/spec/spec_helper.rb +50 -0
- metadata +118 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: eee0f0b9219262f64867a14d86fdf09248c562da
|
4
|
+
data.tar.gz: 16360630150035832672c03e26a0c0c2b1eda8c1
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: bd22263b2941170f67f18828a59448bf3f425059c9319e02699eff3e863c8736ab630de51057ee83226a3bb9464eb4aa7513868b2d6fce13ecc3a973a45f9887
|
7
|
+
data.tar.gz: 1f2b328634ce308755e696949e42b5ab62d1c135421732f998b0f79038a65a80e3e4a33291f383db5b0d8a3931b6bb58b1fd9f3f9d297d06fac93daeb907c1ce
|
data/.gitignore
ADDED
data/Gemfile
ADDED
data/Gemfile.lock
ADDED
@@ -0,0 +1,103 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
cocoapods-store (0.0.1)
|
5
|
+
|
6
|
+
GEM
|
7
|
+
remote: https://rubygems.org/
|
8
|
+
specs:
|
9
|
+
CFPropertyList (2.3.5)
|
10
|
+
activesupport (4.2.9)
|
11
|
+
i18n (~> 0.7)
|
12
|
+
minitest (~> 5.1)
|
13
|
+
thread_safe (~> 0.3, >= 0.3.4)
|
14
|
+
tzinfo (~> 1.1)
|
15
|
+
aws-sdk (2.10.19)
|
16
|
+
aws-sdk-resources (= 2.10.19)
|
17
|
+
aws-sdk-core (2.10.19)
|
18
|
+
aws-sigv4 (~> 1.0)
|
19
|
+
jmespath (~> 1.0)
|
20
|
+
aws-sdk-resources (2.10.19)
|
21
|
+
aws-sdk-core (= 2.10.19)
|
22
|
+
aws-sigv4 (1.0.1)
|
23
|
+
bacon (1.2.0)
|
24
|
+
claide (1.0.2)
|
25
|
+
cocoapods (1.2.1)
|
26
|
+
activesupport (>= 4.0.2, < 5)
|
27
|
+
claide (>= 1.0.1, < 2.0)
|
28
|
+
cocoapods-core (= 1.2.1)
|
29
|
+
cocoapods-deintegrate (>= 1.0.1, < 2.0)
|
30
|
+
cocoapods-downloader (>= 1.1.3, < 2.0)
|
31
|
+
cocoapods-plugins (>= 1.0.0, < 2.0)
|
32
|
+
cocoapods-search (>= 1.0.0, < 2.0)
|
33
|
+
cocoapods-stats (>= 1.0.0, < 2.0)
|
34
|
+
cocoapods-trunk (>= 1.2.0, < 2.0)
|
35
|
+
cocoapods-try (>= 1.1.0, < 2.0)
|
36
|
+
colored2 (~> 3.1)
|
37
|
+
escape (~> 0.0.4)
|
38
|
+
fourflusher (~> 2.0.1)
|
39
|
+
gh_inspector (~> 1.0)
|
40
|
+
molinillo (~> 0.5.7)
|
41
|
+
nap (~> 1.0)
|
42
|
+
ruby-macho (~> 1.1)
|
43
|
+
xcodeproj (>= 1.4.4, < 2.0)
|
44
|
+
cocoapods-core (1.2.1)
|
45
|
+
activesupport (>= 4.0.2, < 5)
|
46
|
+
fuzzy_match (~> 2.0.4)
|
47
|
+
nap (~> 1.0)
|
48
|
+
cocoapods-deintegrate (1.0.1)
|
49
|
+
cocoapods-downloader (1.1.3)
|
50
|
+
cocoapods-plugins (1.0.0)
|
51
|
+
nap
|
52
|
+
cocoapods-search (1.0.0)
|
53
|
+
cocoapods-stats (1.0.0)
|
54
|
+
cocoapods-trunk (1.2.0)
|
55
|
+
nap (>= 0.8, < 2.0)
|
56
|
+
netrc (= 0.7.8)
|
57
|
+
cocoapods-try (1.1.0)
|
58
|
+
colored2 (3.1.2)
|
59
|
+
escape (0.0.4)
|
60
|
+
fourflusher (2.0.1)
|
61
|
+
fuzzy_match (2.0.4)
|
62
|
+
gh_inspector (1.0.3)
|
63
|
+
i18n (0.8.6)
|
64
|
+
jmespath (1.3.1)
|
65
|
+
metaclass (0.0.4)
|
66
|
+
minitest (5.10.3)
|
67
|
+
mocha (1.2.1)
|
68
|
+
metaclass (~> 0.0.1)
|
69
|
+
mocha-on-bacon (0.2.3)
|
70
|
+
mocha (>= 0.13.0)
|
71
|
+
molinillo (0.5.7)
|
72
|
+
nanaimo (0.2.3)
|
73
|
+
nap (1.1.0)
|
74
|
+
netrc (0.7.8)
|
75
|
+
prettybacon (0.0.2)
|
76
|
+
bacon (~> 1.2)
|
77
|
+
rake (12.0.0)
|
78
|
+
ruby-macho (1.1.0)
|
79
|
+
thread_safe (0.3.6)
|
80
|
+
tzinfo (1.2.3)
|
81
|
+
thread_safe (~> 0.1)
|
82
|
+
xcodeproj (1.5.1)
|
83
|
+
CFPropertyList (~> 2.3.3)
|
84
|
+
claide (>= 1.0.2, < 2.0)
|
85
|
+
colored2 (~> 3.1)
|
86
|
+
nanaimo (~> 0.2.3)
|
87
|
+
|
88
|
+
PLATFORMS
|
89
|
+
ruby
|
90
|
+
|
91
|
+
DEPENDENCIES
|
92
|
+
aws-sdk
|
93
|
+
bacon
|
94
|
+
bundler (~> 1.3)
|
95
|
+
cocoapods
|
96
|
+
cocoapods-store!
|
97
|
+
mocha
|
98
|
+
mocha-on-bacon
|
99
|
+
prettybacon
|
100
|
+
rake
|
101
|
+
|
102
|
+
BUNDLED WITH
|
103
|
+
1.15.3
|
data/LICENSE.txt
ADDED
@@ -0,0 +1,22 @@
|
|
1
|
+
Copyright (c) 2017 Jack Newcombe <jack@newcombe.io>
|
2
|
+
|
3
|
+
MIT License
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
6
|
+
a copy of this software and associated documentation files (the
|
7
|
+
"Software"), to deal in the Software without restriction, including
|
8
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
9
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
10
|
+
permit persons to whom the Software is furnished to do so, subject to
|
11
|
+
the following conditions:
|
12
|
+
|
13
|
+
The above copyright notice and this permission notice shall be
|
14
|
+
included in all copies or substantial portions of the Software.
|
15
|
+
|
16
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
17
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
18
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
19
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
20
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
21
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
22
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,52 @@
|
|
1
|
+
# cocoapods-store
|
2
|
+
|
3
|
+
cocoapods-store is a plugin that lets you load push and pull dependencies to
|
4
|
+
and from an s3 bucket.
|
5
|
+
|
6
|
+
Pushes are keyed against the commit they are linked to the commit allowing them
|
7
|
+
to be pulled on demand.
|
8
|
+
|
9
|
+
This provides a faster alternative to pulling repos separately when running
|
10
|
+
pod install or pod update.
|
11
|
+
|
12
|
+
This gives several benefits:
|
13
|
+
|
14
|
+
- Pods only have to be installed once for the given commit avoiding multiple
|
15
|
+
requests to Github and other stores for subsequent installs
|
16
|
+
- Continuous integration agents can pull from the store helping to decrease
|
17
|
+
build times
|
18
|
+
|
19
|
+
## Installation
|
20
|
+
```bash
|
21
|
+
$ gem install cocoapods-store
|
22
|
+
```
|
23
|
+
## Usage
|
24
|
+
|
25
|
+
```bash
|
26
|
+
$ pod spec push --bucket "my-pod-store" --aws-key "KEY" --aws-secret "SECRET"
|
27
|
+
|
28
|
+
$ pod spec pull --bucket "my-pod-store" --aws-key "KEY" --aws-secret "SECRET"
|
29
|
+
```
|
30
|
+
|
31
|
+
It is recommended that you create a `.cocoapods-store.yml` rather than passing
|
32
|
+
arguments. The yaml should have the following format:
|
33
|
+
|
34
|
+
```yaml
|
35
|
+
bucket: "my-pod-store"
|
36
|
+
aws-key: "KEY"
|
37
|
+
aws-secret: "SECRET"
|
38
|
+
```
|
39
|
+
|
40
|
+
With a yaml file in place, you can simply call:
|
41
|
+
|
42
|
+
```bash
|
43
|
+
$ pod spec push
|
44
|
+
|
45
|
+
$ pod spec pull
|
46
|
+
```
|
47
|
+
|
48
|
+
## Roadmap
|
49
|
+
|
50
|
+
- [x] S3 support
|
51
|
+
- [ ] Implicit Installation
|
52
|
+
- [ ] Cache built frameworks
|
data/Rakefile
ADDED
@@ -0,0 +1,25 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'cocoapods-store/gem_version.rb'
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = 'cocoapods-store'
|
8
|
+
spec.version = CocoapodsStore::VERSION
|
9
|
+
spec.authors = ['Jack Newcombe']
|
10
|
+
spec.email = ['jack@newcombe.io']
|
11
|
+
spec.description = %q{A short description of cocoapods-store.}
|
12
|
+
spec.summary = %q{A longer description of cocoapods-store.}
|
13
|
+
spec.homepage = 'https://github.com/EXAMPLE/cocoapods-store'
|
14
|
+
spec.license = 'MIT'
|
15
|
+
|
16
|
+
spec.files = `git ls-files`.split($/)
|
17
|
+
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
18
|
+
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
19
|
+
spec.require_paths = ['lib']
|
20
|
+
|
21
|
+
spec.add_development_dependency 'bundler', '~> 1.3'
|
22
|
+
spec.add_development_dependency 'rake'
|
23
|
+
spec.add_development_dependency 'cocoapods'
|
24
|
+
spec.add_development_dependency 'aws-sdk'
|
25
|
+
end
|
@@ -0,0 +1 @@
|
|
1
|
+
require 'cocoapods-store/gem_version'
|
@@ -0,0 +1 @@
|
|
1
|
+
require 'cocoapods-store/command/store'
|
@@ -0,0 +1,88 @@
|
|
1
|
+
require 'cocoapods-store/command/store/push'
|
2
|
+
require 'cocoapods-store/command/store/pull'
|
3
|
+
|
4
|
+
module Pod
|
5
|
+
class Command
|
6
|
+
|
7
|
+
# This is an example of a cocoapods plugin adding a top-level subcommand
|
8
|
+
# to the 'pod' command.
|
9
|
+
#
|
10
|
+
# You can also create subcommands of existing or new commands. Say you
|
11
|
+
# wanted to add a subcommand to `list` to show newly deprecated pods,
|
12
|
+
# (e.g. `pod list deprecated`), there are a few things that would need
|
13
|
+
# to change.
|
14
|
+
#
|
15
|
+
# - move this file to `lib/pod/command/list/deprecated.rb` and update
|
16
|
+
# the class to exist in the the Pod::Command::List namespace
|
17
|
+
# - change this class to extend from `List` instead of `Command`. This
|
18
|
+
# tells the plugin system that it is a subcommand of `list`.
|
19
|
+
# - edit `lib/cocoapods_plugins.rb` to require this file
|
20
|
+
#
|
21
|
+
# @todo Create a PR to add your plugin to CocoaPods/cocoapods.org
|
22
|
+
# in the `plugins.json` file, once your plugin is released.
|
23
|
+
#
|
24
|
+
class Store < Command
|
25
|
+
|
26
|
+
self.description = "Manage a pod installation store"
|
27
|
+
|
28
|
+
self.abstract_command = true
|
29
|
+
|
30
|
+
|
31
|
+
def self.options
|
32
|
+
[
|
33
|
+
['--bucket', 'The bucket to use as the store.' ],
|
34
|
+
['--aws-key', 'Your AWS access key ID.' ],
|
35
|
+
['--aws-secret', 'Your AWS secret access key.' ]
|
36
|
+
]
|
37
|
+
end
|
38
|
+
|
39
|
+
def initialize(argv)
|
40
|
+
super
|
41
|
+
|
42
|
+
prefs_file = '.cocoapods-store.yml'
|
43
|
+
prefs = (File.exist?(prefs_file) && YAML.load_file(prefs_file)) || {}
|
44
|
+
|
45
|
+
@bucket = argv.option('bucket', nil) || prefs['bucket']
|
46
|
+
@aws_public_key = argv.option('aws-key', nil) || prefs['aws-key']
|
47
|
+
@aws_private_key = argv.option('aws-secret', nil) || prefs['aws-secret']
|
48
|
+
|
49
|
+
end
|
50
|
+
|
51
|
+
def validate!
|
52
|
+
super
|
53
|
+
|
54
|
+
help! "A bucket must be specified using --bucket" unless @bucket
|
55
|
+
help! "An AWS access key ID must be specified using --aws-key" unless @aws_public_key
|
56
|
+
help! "An AWS secret access key must be specified using --aws-secret" unless @aws_private_key
|
57
|
+
end
|
58
|
+
|
59
|
+
# Methods
|
60
|
+
|
61
|
+
def load_s3_bucket
|
62
|
+
Aws.config[:region] = 'eu-west-1' # Required for config, but unneeded by S3
|
63
|
+
|
64
|
+
client = Aws::S3::Client.new(
|
65
|
+
access_key_id: @aws_public_key,
|
66
|
+
secret_access_key: @aws_private_key,
|
67
|
+
)
|
68
|
+
|
69
|
+
return Aws::S3::Resource.new(client: client)
|
70
|
+
end
|
71
|
+
|
72
|
+
# Accessors
|
73
|
+
|
74
|
+
def commit
|
75
|
+
return `git show --pretty=%H`
|
76
|
+
end
|
77
|
+
|
78
|
+
def project_name
|
79
|
+
return Pathname.new(Dir.pwd).basename
|
80
|
+
end
|
81
|
+
|
82
|
+
def cache_dir_name
|
83
|
+
return "#{project_name}-#{commit.strip!}"
|
84
|
+
end
|
85
|
+
|
86
|
+
end
|
87
|
+
end
|
88
|
+
end
|
@@ -0,0 +1,76 @@
|
|
1
|
+
require 'aws-sdk'
|
2
|
+
require 'yaml'
|
3
|
+
|
4
|
+
module Pod
|
5
|
+
class Command
|
6
|
+
class Store < Command
|
7
|
+
|
8
|
+
class Pull < Store
|
9
|
+
|
10
|
+
self.summary = 'Pulls down and integrates installation data.'
|
11
|
+
|
12
|
+
self.description = <<-DESC
|
13
|
+
Pulls down and integrates installation data
|
14
|
+
DESC
|
15
|
+
|
16
|
+
# Plugin Lifecycle
|
17
|
+
|
18
|
+
def initialize(argv)
|
19
|
+
super
|
20
|
+
end
|
21
|
+
|
22
|
+
def validate!
|
23
|
+
super
|
24
|
+
end
|
25
|
+
|
26
|
+
def run
|
27
|
+
|
28
|
+
verify_podfile_exists!
|
29
|
+
|
30
|
+
pull_from_store
|
31
|
+
replace_installation_data
|
32
|
+
end
|
33
|
+
|
34
|
+
# Run steps
|
35
|
+
|
36
|
+
def pull_from_store
|
37
|
+
|
38
|
+
s3 = load_s3_bucket
|
39
|
+
|
40
|
+
zip_name = "#{cache_dir_name}.zip"
|
41
|
+
|
42
|
+
obj = s3.bucket(@bucket).object(zip_name)
|
43
|
+
|
44
|
+
if !obj.exists?
|
45
|
+
UI.puts "Item does not exist in cache"
|
46
|
+
exit
|
47
|
+
end
|
48
|
+
|
49
|
+
UI.puts "Downloading #{zip_name}"
|
50
|
+
|
51
|
+
success = obj.download_file(zip_name)
|
52
|
+
|
53
|
+
if !success
|
54
|
+
UI.puts "An error occurred attempt to download the cache item"
|
55
|
+
exit
|
56
|
+
end
|
57
|
+
|
58
|
+
end
|
59
|
+
|
60
|
+
def replace_installation_data
|
61
|
+
|
62
|
+
zip_name = "#{cache_dir_name}.zip"
|
63
|
+
|
64
|
+
FileUtils.rm_rf "#{Dir.pwd}/Pods"
|
65
|
+
FileUtils.rm_rf Dir.glob("#{Dir.pwd}/*.xcworkspace").first || ""
|
66
|
+
FileUtils.rm_rf "#{Dir.pwd}/Podfile.lock"
|
67
|
+
|
68
|
+
system "unzip #{zip_name} > /dev/null"
|
69
|
+
|
70
|
+
end
|
71
|
+
|
72
|
+
end
|
73
|
+
|
74
|
+
end
|
75
|
+
end
|
76
|
+
end
|
@@ -0,0 +1,96 @@
|
|
1
|
+
require 'aws-sdk'
|
2
|
+
|
3
|
+
module Pod
|
4
|
+
class Command
|
5
|
+
class Store < Command
|
6
|
+
|
7
|
+
class Push < Store
|
8
|
+
|
9
|
+
self.summary = 'Stores cocoapods installation data for quicker installation'
|
10
|
+
|
11
|
+
self.description = <<-DESC
|
12
|
+
Stores cocoapods installation data for quicker installation
|
13
|
+
DESC
|
14
|
+
|
15
|
+
|
16
|
+
# Accessors
|
17
|
+
|
18
|
+
def commit
|
19
|
+
return `git show --pretty=%H`
|
20
|
+
end
|
21
|
+
|
22
|
+
# Plugin Lifecycle
|
23
|
+
|
24
|
+
def initialize(argv)
|
25
|
+
super
|
26
|
+
end
|
27
|
+
|
28
|
+
def validate!
|
29
|
+
super
|
30
|
+
end
|
31
|
+
|
32
|
+
def run
|
33
|
+
|
34
|
+
verify_podfile_exists!
|
35
|
+
verify_lockfile_exists!
|
36
|
+
|
37
|
+
archive_cache
|
38
|
+
push_cache
|
39
|
+
end
|
40
|
+
|
41
|
+
# Run steps
|
42
|
+
|
43
|
+
def archive_cache
|
44
|
+
|
45
|
+
@cache_dir = "#{Dir.pwd}/#{cache_dir_name}"
|
46
|
+
|
47
|
+
UI.puts "Creating cache directory: #{@cache_dir}"
|
48
|
+
|
49
|
+
FileUtils.rm_rf @cache_dir
|
50
|
+
FileUtils.mkdir_p @cache_dir
|
51
|
+
|
52
|
+
# Copy files to the cache folder
|
53
|
+
begin
|
54
|
+
FileUtils.cp_r "#{Dir.pwd}/Pods", @cache_dir
|
55
|
+
FileUtils.cp_r Dir.glob("#{Dir.pwd}/*.xcworkspace").first, @cache_dir
|
56
|
+
FileUtils.cp_r "#{Dir.pwd}/Podfile.lock", @cache_dir
|
57
|
+
rescue RuntimeError => e
|
58
|
+
UI.puts "[!] An error occurred - #{e.message}".red
|
59
|
+
FileUtils.rm_rf @cache_dir
|
60
|
+
exit 1
|
61
|
+
end
|
62
|
+
|
63
|
+
# Archive the cache folder
|
64
|
+
@zip_name = "#{cache_dir_name}.zip"
|
65
|
+
system "ditto -ck --rsrc --sequesterRsrc #{cache_dir_name} #{@zip_name}"
|
66
|
+
end
|
67
|
+
|
68
|
+
def push_cache
|
69
|
+
|
70
|
+
begin
|
71
|
+
s3 = load_s3_bucket
|
72
|
+
|
73
|
+
obj = s3.bucket('pod-store').object(@zip_name)
|
74
|
+
UI.puts "Uploading #{@zip_name}"
|
75
|
+
obj.upload_file("#{Dir.pwd}/#{@zip_name}")
|
76
|
+
|
77
|
+
UI.puts "✔︎ Cache uploaded successfully".green.bold
|
78
|
+
|
79
|
+
rescue Aws::Errors::MissingCredentialsError => e
|
80
|
+
UI.puts "S3 upload failed: Credentials were not present".red.bold
|
81
|
+
rescue Aws::S3::Errors::NoSuchBucket => e
|
82
|
+
UI.puts "S3 upload failed: the bucket specified does not exist".red.bold
|
83
|
+
rescue Aws::Errors::ServiceError => e
|
84
|
+
UI.puts "[!] S3 upload failed: A service error occurred - #{e.message}".red.bold
|
85
|
+
ensure
|
86
|
+
FileUtils.rm_rf @cache_dir
|
87
|
+
FileUtils.rm_rf "#{Dir.pwd}/#{@zip_name}"
|
88
|
+
end
|
89
|
+
|
90
|
+
end
|
91
|
+
|
92
|
+
end # class Push
|
93
|
+
|
94
|
+
end # class Store
|
95
|
+
end # class Command
|
96
|
+
end # module Pod
|
@@ -0,0 +1 @@
|
|
1
|
+
require 'cocoapods-store/command'
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,50 @@
|
|
1
|
+
require 'pathname'
|
2
|
+
ROOT = Pathname.new(File.expand_path('../../', __FILE__))
|
3
|
+
$:.unshift((ROOT + 'lib').to_s)
|
4
|
+
$:.unshift((ROOT + 'spec').to_s)
|
5
|
+
|
6
|
+
require 'bundler/setup'
|
7
|
+
require 'bacon'
|
8
|
+
require 'mocha-on-bacon'
|
9
|
+
require 'pretty_bacon'
|
10
|
+
require 'pathname'
|
11
|
+
require 'cocoapods'
|
12
|
+
|
13
|
+
Mocha::Configuration.prevent(:stubbing_non_existent_method)
|
14
|
+
|
15
|
+
require 'cocoapods_plugin'
|
16
|
+
|
17
|
+
#-----------------------------------------------------------------------------#
|
18
|
+
|
19
|
+
module Pod
|
20
|
+
|
21
|
+
# Disable the wrapping so the output is deterministic in the tests.
|
22
|
+
#
|
23
|
+
UI.disable_wrap = true
|
24
|
+
|
25
|
+
# Redirects the messages to an internal store.
|
26
|
+
#
|
27
|
+
module UI
|
28
|
+
@output = ''
|
29
|
+
@warnings = ''
|
30
|
+
|
31
|
+
class << self
|
32
|
+
attr_accessor :output
|
33
|
+
attr_accessor :warnings
|
34
|
+
|
35
|
+
def puts(message = '')
|
36
|
+
@output << "#{message}\n"
|
37
|
+
end
|
38
|
+
|
39
|
+
def warn(message = '', actions = [])
|
40
|
+
@warnings << "#{message}\n"
|
41
|
+
end
|
42
|
+
|
43
|
+
def print(message)
|
44
|
+
@output << message
|
45
|
+
end
|
46
|
+
end
|
47
|
+
end
|
48
|
+
end
|
49
|
+
|
50
|
+
#-----------------------------------------------------------------------------#
|
metadata
ADDED
@@ -0,0 +1,118 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: cocoapods-store
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Jack Newcombe
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2017-07-31 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ~>
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '1.3'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ~>
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.3'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - '>='
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - '>='
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: cocoapods
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - '>='
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - '>='
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: aws-sdk
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - '>='
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - '>='
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
description: A short description of cocoapods-store.
|
70
|
+
email:
|
71
|
+
- jack@newcombe.io
|
72
|
+
executables: []
|
73
|
+
extensions: []
|
74
|
+
extra_rdoc_files: []
|
75
|
+
files:
|
76
|
+
- .gitignore
|
77
|
+
- Gemfile
|
78
|
+
- Gemfile.lock
|
79
|
+
- LICENSE.txt
|
80
|
+
- README.md
|
81
|
+
- Rakefile
|
82
|
+
- cocoapods-store.gemspec
|
83
|
+
- lib/cocoapods-store.rb
|
84
|
+
- lib/cocoapods-store/command.rb
|
85
|
+
- lib/cocoapods-store/command/store.rb
|
86
|
+
- lib/cocoapods-store/command/store/pull.rb
|
87
|
+
- lib/cocoapods-store/command/store/push.rb
|
88
|
+
- lib/cocoapods-store/gem_version.rb
|
89
|
+
- lib/cocoapods_plugin.rb
|
90
|
+
- spec/command/store_spec.rb
|
91
|
+
- spec/spec_helper.rb
|
92
|
+
homepage: https://github.com/EXAMPLE/cocoapods-store
|
93
|
+
licenses:
|
94
|
+
- MIT
|
95
|
+
metadata: {}
|
96
|
+
post_install_message:
|
97
|
+
rdoc_options: []
|
98
|
+
require_paths:
|
99
|
+
- lib
|
100
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
101
|
+
requirements:
|
102
|
+
- - '>='
|
103
|
+
- !ruby/object:Gem::Version
|
104
|
+
version: '0'
|
105
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
106
|
+
requirements:
|
107
|
+
- - '>='
|
108
|
+
- !ruby/object:Gem::Version
|
109
|
+
version: '0'
|
110
|
+
requirements: []
|
111
|
+
rubyforge_project:
|
112
|
+
rubygems_version: 2.0.14.1
|
113
|
+
signing_key:
|
114
|
+
specification_version: 4
|
115
|
+
summary: A longer description of cocoapods-store.
|
116
|
+
test_files:
|
117
|
+
- spec/command/store_spec.rb
|
118
|
+
- spec/spec_helper.rb
|