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
e78acd84
Commit
e78acd84
authored
Apr 01, 2014
by
Marius Rackwitz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Implemented update_mode == :selected
parent
ac04c590
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
9 deletions
+14
-9
analyzer.rb
lib/cocoapods/installer/analyzer.rb
+14
-9
No files found.
lib/cocoapods/installer/analyzer.rb
View file @
e78acd84
...
@@ -238,12 +238,15 @@ module Pod
...
@@ -238,12 +238,15 @@ module Pod
# that prevent the resolver to update a Pod.
# that prevent the resolver to update a Pod.
#
#
def
generate_version_locking_dependencies
def
generate_version_locking_dependencies
# TODO: Add a case for specific pods
if
update_mode
==
:all
case
update_mode
when
:all
[]
[]
when
:none
else
result
.
podfile_state
.
unchanged
.
map
do
|
pod
|
locking_pods
=
result
.
podfile_state
.
unchanged
if
update_mode
==
:selected
# If selected Pods should been updated, filter them out of the list
locking_pods
.
select!
{
|
pod
|
!
update
[
:pods
].
include?
(
pod
)
}
end
locking_pods
.
map
do
|
pod
|
lockfile
.
dependency_to_lock_pod_named
(
pod
)
lockfile
.
dependency_to_lock_pod_named
(
pod
)
end
end
end
end
...
@@ -273,12 +276,14 @@ module Pod
...
@@ -273,12 +276,14 @@ module Pod
deps_to_fetch
=
[]
deps_to_fetch
=
[]
deps_to_fetch_if_needed
=
[]
deps_to_fetch_if_needed
=
[]
deps_with_external_source
=
podfile
.
dependencies
.
select
{
|
dep
|
dep
.
external_source
}
deps_with_external_source
=
podfile
.
dependencies
.
select
{
|
dep
|
dep
.
external_source
}
# TODO: Add a case for specific pods
case
update_mode
if
update_mode
==
:all
when
:all
deps_to_fetch
=
deps_with_external_source
deps_to_fetch
=
deps_with_external_source
when
:non
e
els
e
pods_to_fetch
=
result
.
podfile_state
.
added
+
result
.
podfile_state
.
changed
pods_to_fetch
=
result
.
podfile_state
.
added
+
result
.
podfile_state
.
changed
if
update_mode
==
:selected
pods_to_fetch
+=
update
[
:pods
]
end
deps_to_fetch
=
deps_with_external_source
.
select
{
|
dep
|
pods_to_fetch
.
include?
(
dep
.
root_name
)
}
deps_to_fetch
=
deps_with_external_source
.
select
{
|
dep
|
pods_to_fetch
.
include?
(
dep
.
root_name
)
}
deps_to_fetch_if_needed
=
deps_with_external_source
.
select
{
|
dep
|
result
.
podfile_state
.
unchanged
.
include?
(
dep
.
root_name
)
}
deps_to_fetch_if_needed
=
deps_with_external_source
.
select
{
|
dep
|
result
.
podfile_state
.
unchanged
.
include?
(
dep
.
root_name
)
}
deps_to_fetch
+=
deps_to_fetch_if_needed
.
select
{
|
dep
|
sandbox
.
specification
(
dep
.
root_name
).
nil?
||
!
dep
.
external_source
[
:local
].
nil?
||
!
dep
.
external_source
[
:path
].
nil?
}
deps_to_fetch
+=
deps_to_fetch_if_needed
.
select
{
|
dep
|
sandbox
.
specification
(
dep
.
root_name
).
nil?
||
!
dep
.
external_source
[
:local
].
nil?
||
!
dep
.
external_source
[
:path
].
nil?
}
...
...
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