Commit 83096348 authored by Marius Rackwitz's avatar Marius Rackwitz

[Refactor] Extract #generate_pod_targets in Analyzer

parent 7c344bdd
......@@ -219,7 +219,23 @@ module Pod
end
end
# Group specs and subspecs by their root
generate_pod_targets(target, specs)
target
end
# Setup the pod targets for an aggregate target. Group specs and subspecs
# by their root to create a {PodTarget} for each spec.
#
# @param [AggregateTarget] target
# the aggregate target
#
# @param [Array<Specification>] specs
# the specifications that need to be installed.
#
# @return [Array<PodTarget>]
#
def generate_pod_targets(target, specs)
grouped_specs = specs.map do |spec|
specs.select { |s| s.root == spec.root }
end.uniq
......@@ -240,7 +256,7 @@ module Pod
target.pod_targets << pod_target
end
target
pod_target
end
# Generates dependencies that require the specific version of the Pods
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment