cocoapods-try 0.5.1 → 1.0.0.beta.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 +4 -4
- data/CHANGELOG.md +10 -0
- data/Gemfile.lock +3 -3
- data/lib/cocoapods_try.rb +1 -2
- data/lib/pod/command/try.rb +6 -7
- data/lib/pod/try_settings.rb +1 -1
- data/spec/command/try_settings_spec.rb +2 -2
- data/spec/command/try_spec.rb +21 -7
- metadata +5 -5
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 57c6b5b53b39607c80d19f9d0da0034842ff3b9c
|
|
4
|
+
data.tar.gz: 01f73347266b2ba72d4eb0aa825930e8db018576
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ebfac998db0581b7fed0695675a59ef71e615d983733570ca8cc82e7164ef99a16daeb89c9fb73a178dcabcfbcbc0b6e881cd6aa22d903a0b677299b6a9c99d4
|
|
7
|
+
data.tar.gz: 80b9dc933c7a471a15314d100c3d866828497e72378a2face4095303633a107ab21680e516e451344e8939fcefae113f335e7f74e9c6ec94f129d6ff289a8f22
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# Cocoapods::Try Changelog
|
|
2
2
|
|
|
3
|
+
|
|
4
|
+
## 1.0.0.beta.1 (2015-12-30)
|
|
5
|
+
|
|
6
|
+
##### Bug Fixes
|
|
7
|
+
|
|
8
|
+
* Ensure commands in the `.cocoapods` file are strings, and uses the pods folder when executing commands.
|
|
9
|
+
[Samuel Giddins](https://github.com/segiddins)
|
|
10
|
+
[CocoaPods-Try#40](https://github.com/CocoaPods/cocoapods-try/issues/40)
|
|
11
|
+
|
|
12
|
+
|
|
3
13
|
## 0.5.1 (2015-08-28)
|
|
4
14
|
|
|
5
15
|
##### Bug Fixes
|
data/Gemfile.lock
CHANGED
|
@@ -18,7 +18,7 @@ GIT
|
|
|
18
18
|
cocoapods-plugins (~> 0.4.2)
|
|
19
19
|
cocoapods-stats (~> 0.5.3)
|
|
20
20
|
cocoapods-trunk (~> 0.6.1)
|
|
21
|
-
cocoapods-try (~> 0.
|
|
21
|
+
cocoapods-try (~> 1.0.0.beta.1)
|
|
22
22
|
colored (~> 1.2)
|
|
23
23
|
escape (~> 0.0.4)
|
|
24
24
|
molinillo (~> 0.3.1)
|
|
@@ -38,7 +38,7 @@ GIT
|
|
|
38
38
|
PATH
|
|
39
39
|
remote: .
|
|
40
40
|
specs:
|
|
41
|
-
cocoapods-try (0.
|
|
41
|
+
cocoapods-try (1.0.0.beta.1)
|
|
42
42
|
|
|
43
43
|
GEM
|
|
44
44
|
remote: https://rubygems.org/
|
|
@@ -123,4 +123,4 @@ DEPENDENCIES
|
|
|
123
123
|
rubocop
|
|
124
124
|
|
|
125
125
|
BUNDLED WITH
|
|
126
|
-
1.
|
|
126
|
+
1.11.2
|
data/lib/cocoapods_try.rb
CHANGED
data/lib/pod/command/try.rb
CHANGED
|
@@ -42,7 +42,7 @@ module Pod
|
|
|
42
42
|
UI.title "Trying #{spec.name}" do
|
|
43
43
|
pod_dir = install_pod(spec, sandbox)
|
|
44
44
|
settings = TrySettings.settings_from_folder(pod_dir)
|
|
45
|
-
settings.run_pre_install_commands(true)
|
|
45
|
+
Dir.chdir(pod_dir) { settings.run_pre_install_commands(true) }
|
|
46
46
|
proj = settings.project_path || pick_demo_project(pod_dir)
|
|
47
47
|
file = install_podfile(proj)
|
|
48
48
|
if file
|
|
@@ -124,12 +124,11 @@ module Pod
|
|
|
124
124
|
#
|
|
125
125
|
def install_pod(spec, sandbox)
|
|
126
126
|
specs = { :ios => spec, :osx => spec }
|
|
127
|
-
clean
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
sandbox.root + spec.name
|
|
127
|
+
config.with_changes(:clean => false) do
|
|
128
|
+
installer = Installer::PodSourceInstaller.new(sandbox, specs)
|
|
129
|
+
installer.install!
|
|
130
|
+
sandbox.root + spec.name
|
|
131
|
+
end
|
|
133
132
|
end
|
|
134
133
|
|
|
135
134
|
# Picks a project or workspace suitable for the demo purposes in the
|
data/lib/pod/try_settings.rb
CHANGED
|
@@ -46,7 +46,7 @@ module Pod
|
|
|
46
46
|
def run_pre_install_commands(prompt)
|
|
47
47
|
if pre_install_commands
|
|
48
48
|
prompt_for_permission if prompt
|
|
49
|
-
pre_install_commands.each { |command| Executable.execute_command('bash', ['-
|
|
49
|
+
pre_install_commands.each { |command| Executable.execute_command('bash', ['-ec', command], true) }
|
|
50
50
|
end
|
|
51
51
|
end
|
|
52
52
|
end
|
|
@@ -59,8 +59,8 @@ YAML
|
|
|
59
59
|
YAML
|
|
60
60
|
File.open(dir + '/.cocoapods.yml', 'w') { |f| f.write(yaml) }
|
|
61
61
|
|
|
62
|
-
Executable.expects(:execute_command).with('bash', ['-
|
|
63
|
-
Executable.expects(:execute_command).with('bash', ['-
|
|
62
|
+
Executable.expects(:execute_command).with('bash', ['-ec', 'pod install'], true)
|
|
63
|
+
Executable.expects(:execute_command).with('bash', ['-ec', 'git submodule init'], true)
|
|
64
64
|
|
|
65
65
|
settings = TrySettings.settings_from_folder dir
|
|
66
66
|
settings.run_pre_install_commands false
|
data/spec/command/try_spec.rb
CHANGED
|
@@ -19,14 +19,28 @@ module Pod
|
|
|
19
19
|
end.message.should.match(/A Pod name or URL is required/)
|
|
20
20
|
end
|
|
21
21
|
|
|
22
|
+
before do
|
|
23
|
+
@original_install_method = method = Pod::Command::Try.instance_method(:install_pod)
|
|
24
|
+
Pod::Command::Try.send(:define_method, :install_pod) do |*args|
|
|
25
|
+
dir = method.bind(self).call(*args)
|
|
26
|
+
FileUtils.mkdir_p(dir)
|
|
27
|
+
dir
|
|
28
|
+
end
|
|
29
|
+
end
|
|
30
|
+
|
|
31
|
+
after do
|
|
32
|
+
Pod::Command::Try.send(:define_method, :install_pod, @original_install_method)
|
|
33
|
+
end
|
|
34
|
+
|
|
22
35
|
it 'allows the user to try the Pod with the given name' do
|
|
23
|
-
Config.instance.skip_repo_update
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
36
|
+
Config.instance.with_changes(:skip_repo_update => false) do
|
|
37
|
+
command = Pod::Command.parse(%w(try ARAnalytics))
|
|
38
|
+
Installer::PodSourceInstaller.any_instance.expects(:install!)
|
|
39
|
+
command.expects(:update_specs_repos)
|
|
40
|
+
command.expects(:pick_demo_project).returns(XCODE_PROJECT)
|
|
41
|
+
command.expects(:open_project).with(XCODE_PROJECT)
|
|
42
|
+
command.run
|
|
43
|
+
end
|
|
30
44
|
end
|
|
31
45
|
|
|
32
46
|
it 'allows the user to try the Pod with the given Git URL' do
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: cocoapods-try
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 1.0.0.beta.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Fabio Pelosin
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2015-
|
|
11
|
+
date: 2015-12-30 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|
|
@@ -78,12 +78,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
78
78
|
version: '0'
|
|
79
79
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
80
80
|
requirements:
|
|
81
|
-
- - '
|
|
81
|
+
- - '>'
|
|
82
82
|
- !ruby/object:Gem::Version
|
|
83
|
-
version:
|
|
83
|
+
version: 1.3.1
|
|
84
84
|
requirements: []
|
|
85
85
|
rubyforge_project:
|
|
86
|
-
rubygems_version: 2.
|
|
86
|
+
rubygems_version: 2.5.1
|
|
87
87
|
signing_key:
|
|
88
88
|
specification_version: 4
|
|
89
89
|
summary: CocoaPods plugin which allows to quickly try the demo project of a Pod.
|