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
131b758a
Commit
131b758a
authored
Oct 04, 2012
by
Fabio Pelosin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Source] Fixed slowness.
parent
8f8e5409
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
3 deletions
+16
-3
CHANGELOG.md
CHANGELOG.md
+1
-0
source.rb
lib/cocoapods/source.rb
+15
-3
No files found.
CHANGELOG.md
View file @
131b758a
...
...
@@ -15,6 +15,7 @@
[
#570
](
https://github.com/CocoaPods/CocoaPods/issues/570
)
-
Fixed a crash for
`pod outdated`
.
[
#567
](
https://github.com/CocoaPods/CocoaPods/issues/567
)
-
Fixed an issue that lead to excessively slow sets computation.
## 0.15.0
...
...
lib/cocoapods/source.rb
View file @
131b758a
...
...
@@ -128,10 +128,22 @@ module Pod
# @return [Array<Set>] The sets for all the pods available.
#
# @note Implementation detail: The sources don't cache their values
# because they might change in response to an update. Therefore
# this method to prevent slowness caches the values before
# processing them.
#
def
all_sets
all_pods
.
map
do
|
pod
|
sources
=
all
.
select
{
|
s
|
s
.
pods
.
include?
(
pod
)
}.
compact
Specification
::
Set
.
new
(
pod
,
sources
)
pods_by_source
=
{}
all
.
each
do
|
source
|
pods_by_source
[
source
]
=
source
.
pods
end
sources
=
pods_by_source
.
keys
pods
=
pods_by_source
.
values
.
flatten
.
uniq
pods
.
map
do
|
pod
|
pod_sources
=
sources
.
select
{
|
s
|
pods_by_source
[
s
].
include?
(
pod
)
}.
compact
Specification
::
Set
.
new
(
pod
,
pod_sources
)
end
end
...
...
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