Commit b85b9bdf authored by Eloy Durán's avatar Eloy Durán

Merge pull request #99 from chriseidhof/master

List command
parents bfac2550 a8c7f085
......@@ -3,6 +3,7 @@ module Pod
autoload :Install, 'cocoapods/command/install'
autoload :Repo, 'cocoapods/command/repo'
autoload :Search, 'cocoapods/command/search'
autoload :List, 'cocoapods/command/list'
autoload :Setup, 'cocoapods/command/setup'
autoload :Spec, 'cocoapods/command/spec'
......@@ -35,6 +36,7 @@ module Pod
"\n" \
" * $ pod setup --help\n" \
" * $ pod search --help\n" \
" * $ pod list --help\n" \
" * $ pod install --help\n" \
" * $ pod repo --help\n" \
" * $ pod spec --help"
......@@ -72,6 +74,7 @@ module Pod
when 'install' then Install
when 'repo' then Repo
when 'search' then Search
when 'list' then List
when 'setup' then Setup
when 'spec' then Spec
end
......
module Pod
class Command
class List < Command
def self.banner
%{List all pods:
$ pod list
Lists all available pods.}
end
def initialize(argv)
end
def run
Source.all.each do |source|
source.pod_sets.each do |set|
puts "==> #{set.name} (#{set.versions.reverse.join(", ")})"
puts " #{set.specification.summary.strip}"
puts
end
end
end
end
end
end
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