Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
cocoapods
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gengmeiios
cocoapods
Commits
6f906c42
Commit
6f906c42
authored
Jun 14, 2015
by
Samuel E. Giddins
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #3659 from DanielTomlinson/feature/cocoapods_version
Add support for cocoapods_version
parents
a9a18603
2bd06e31
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
0 deletions
+8
-0
analyzer.rb
lib/cocoapods/installer/analyzer.rb
+1
-0
podspec_finder.rb
lib/cocoapods/sandbox/podspec_finder.rb
+1
-0
analyzer_spec.rb
spec/unit/installer/analyzer_spec.rb
+6
-0
No files found.
lib/cocoapods/installer/analyzer.rb
View file @
6f906c42
...
@@ -451,6 +451,7 @@ module Pod
...
@@ -451,6 +451,7 @@ module Pod
UI
.
section
"Resolving dependencies of
#{
UI
.
path
podfile
.
defined_in_file
}
"
do
UI
.
section
"Resolving dependencies of
#{
UI
.
path
podfile
.
defined_in_file
}
"
do
resolver
=
Resolver
.
new
(
sandbox
,
podfile
,
locked_dependencies
,
sources
)
resolver
=
Resolver
.
new
(
sandbox
,
podfile
,
locked_dependencies
,
sources
)
specs_by_target
=
resolver
.
resolve
specs_by_target
=
resolver
.
resolve
specs_by_target
.
values
.
flatten
(
1
).
each
(
&
:validate_cocoapods_version
)
end
end
specs_by_target
specs_by_target
end
end
...
...
lib/cocoapods/sandbox/podspec_finder.rb
View file @
6f906c42
...
@@ -14,6 +14,7 @@ module Pod
...
@@ -14,6 +14,7 @@ module Pod
spec_files
.
sort_by
{
|
p
|
-
p
.
to_path
.
split
(
File
::
SEPARATOR
).
size
}.
each
do
|
file
|
spec_files
.
sort_by
{
|
p
|
-
p
.
to_path
.
split
(
File
::
SEPARATOR
).
size
}.
each
do
|
file
|
begin
begin
spec
=
Specification
.
from_file
(
file
)
spec
=
Specification
.
from_file
(
file
)
spec
.
validate_cocoapods_version
@specs_by_name
[
spec
.
name
]
=
spec
@specs_by_name
[
spec
.
name
]
=
spec
rescue
=>
e
rescue
=>
e
UI
.
warn
"Unable to load a podspec from `
#{
file
.
basename
}
`, skipping:
\n\n
#{
e
}
"
UI
.
warn
"Unable to load a podspec from `
#{
file
.
basename
}
`, skipping:
\n\n
#{
e
}
"
...
...
spec/unit/installer/analyzer_spec.rb
View file @
6f906c42
...
@@ -301,6 +301,12 @@ module Pod
...
@@ -301,6 +301,12 @@ module Pod
UI
.
warnings
.
should
.
match
/RestKit \(<= 0.23.2\)/
UI
.
warnings
.
should
.
match
/RestKit \(<= 0.23.2\)/
end
end
it
'raises when specs have incompatible cocoapods requirements'
do
analyzer
=
Pod
::
Installer
::
Analyzer
.
new
(
config
.
sandbox
,
@podfile
,
nil
)
Specification
.
any_instance
.
stubs
(
:cocoapods_version
).
returns
(
Requirement
.
create
'= 0.1.0'
)
should
.
raise
(
Informative
)
{
analyzer
.
analyze
}
end
#--------------------------------------#
#--------------------------------------#
it
'computes the state of the Sandbox respect to the resolved dependencies'
do
it
'computes the state of the Sandbox respect to the resolved dependencies'
do
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment