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
31dee085
Commit
31dee085
authored
Feb 05, 2018
by
Samuel Giddins
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Preserve external sources on locked dependencies in the resolver
parent
1bee09aa
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
9 deletions
+15
-9
CHANGELOG.md
CHANGELOG.md
+3
-0
Gemfile.lock
Gemfile.lock
+1
-1
locking_dependency_analyzer.rb
...coapods/installer/analyzer/locking_dependency_analyzer.rb
+7
-6
resolver.rb
lib/cocoapods/resolver.rb
+4
-2
No files found.
CHANGELOG.md
View file @
31dee085
...
...
@@ -66,6 +66,9 @@ To install release candidates run `[sudo] gem install cocoapods --pre`
*
Speed up
`pod install`
times by up to 50% for very large project.
[
Samuel Giddins
](
https://github.com/segiddins
)
*
Avoid dependency resolution conflicts when a pod depends upon a local pod.
[
Samuel Giddins
](
https://github.com/segiddins
)
## 1.4.0 (2018-01-18)
...
...
Gemfile.lock
View file @
31dee085
...
...
@@ -250,7 +250,7 @@ GEM
terminal-table (1.6.0)
thread_safe (0.3.6)
tins (1.8.1)
tzinfo (1.2.
4
)
tzinfo (1.2.
5
)
thread_safe (~> 0.1)
unicode-display_width (0.3.1)
webmock (2.3.1)
...
...
lib/cocoapods/installer/analyzer/locking_dependency_analyzer.rb
View file @
31dee085
...
...
@@ -33,10 +33,9 @@ module Pod
dependency_graph
=
Molinillo
::
DependencyGraph
.
new
if
lockfile
explicit_dependencies
=
lockfile
.
to_hash
[
'DEPENDENCIES'
]
||
[]
explicit_dependencies
.
each
do
|
string
|
dependency
=
Dependency
.
new
(
string
)
dependency_graph
.
add_vertex
(
dependency
.
name
,
nil
,
true
)
explicit_dependencies
=
lockfile
.
dependencies
explicit_dependencies
.
each
do
|
dependency
|
dependency_graph
.
add_vertex
(
dependency
.
name
,
dependency
,
true
)
end
pods
=
lockfile
.
to_hash
[
'PODS'
]
||
[]
...
...
@@ -46,7 +45,7 @@ module Pod
pods_to_update
=
pods_to_update
.
flat_map
do
|
u
|
root_name
=
Specification
.
root_name
(
u
).
downcase
dependency_graph
.
vertices
.
keys
.
select
{
|
n
|
Specification
.
root_name
(
n
).
downcase
==
root_name
}
dependency_graph
.
vertices
.
each_key
.
select
{
|
n
|
Specification
.
root_name
(
n
).
downcase
==
root_name
}
end
pods_to_update
.
each
do
|
u
|
...
...
@@ -73,7 +72,9 @@ module Pod
if
pods_to_unlock
.
include?
(
dependency
.
root_name
)
dependency
=
Dependency
.
new
(
dependency
.
name
)
end
dependency_graph
.
add_child_vertex
(
dependency
.
name
,
parents
.
empty?
?
dependency
:
nil
,
parents
,
nil
)
vertex
=
dependency_graph
.
add_child_vertex
(
dependency
.
name
,
nil
,
parents
,
nil
)
dependency
=
vertex
.
payload
.
merge
(
dependency
)
if
vertex
.
payload
vertex
.
payload
=
dependency
dependency
end
...
...
lib/cocoapods/resolver.rb
View file @
31dee085
...
...
@@ -163,7 +163,9 @@ module Pod
def
search_for
(
dependency
)
@search
||=
{}
@search
[
dependency
]
||=
begin
specifications_for_dependency
(
dependency
,
[
requirement_for_locked_pod_named
(
dependency
.
name
)])
locked_requirement
=
requirement_for_locked_pod_named
(
dependency
.
name
)
additional_requirements
=
Array
(
locked_requirement
)
specifications_for_dependency
(
dependency
,
additional_requirements
)
end
@search
[
dependency
].
dup
end
...
...
@@ -357,7 +359,7 @@ module Pod
# @return [Array<Specification>] List of specifications satisfying given requirements.
#
def
specifications_for_dependency
(
dependency
,
additional_requirements
=
[])
requirement
=
Requirement
.
new
(
dependency
.
requirement
.
as_list
+
additional_requirements
)
requirement
=
Requirement
.
new
(
dependency
.
requirement
.
as_list
+
additional_requirements
.
flat_map
(
&
:as_list
)
)
find_cached_set
(
dependency
).
all_specifications
(
installation_options
.
warn_for_multiple_pod_sources
).
select
{
|
s
|
requirement
.
satisfied_by?
s
.
version
}.
...
...
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