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
25e76f42
Commit
25e76f42
authored
Mar 09, 2016
by
Daniel Tomlinson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[SourceManager] Update to setup Aggregate by Source
parent
436c0e2f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
1 deletion
+12
-1
sources_manager.rb
lib/cocoapods/sources_manager.rb
+12
-1
No files found.
lib/cocoapods/sources_manager.rb
View file @
25e76f42
...
@@ -468,14 +468,25 @@ module Pod
...
@@ -468,14 +468,25 @@ module Pod
private
private
# @return [Source] The Source at a given path.
#
# @param [Pathname] path
# The local file path to one podspec repo.
#
def
source_from_path
(
path
)
return
Source
.
new
(
path
)
unless
path
.
basename
.
to_s
==
'master'
return
MasterSource
.
new
(
path
)
end
# @return [Source::Aggregate] The aggregate of the sources from repos.
# @return [Source::Aggregate] The aggregate of the sources from repos.
#
#
# @param [Array<Pathname>] repos
# @param [Array<Pathname>] repos
# The local file paths to one or more podspec repo caches.
# The local file paths to one or more podspec repo caches.
#
#
def
aggregate_with_repos
(
repos
)
def
aggregate_with_repos
(
repos
)
sources
=
repos
.
map
{
|
path
|
source_from_path
(
path
)
}
@aggregates_by_repos
||=
{}
@aggregates_by_repos
||=
{}
@aggregates_by_repos
[
repos
]
||=
Source
::
Aggregate
.
new
(
repo
s
)
@aggregates_by_repos
[
repos
]
||=
Source
::
Aggregate
.
new
(
source
s
)
end
end
# @return [Bool] Whether the given path is writable by the current user.
# @return [Bool] Whether the given path is writable by the current user.
...
...
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