Class: Pod::Command::List
- Inherits:
-
Pod::Command
- Object
- CLAide::Command
- Pod::Command
- Pod::Command::List
- Defined in:
- lib/cocoapods/command/list.rb
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(argv) ⇒ List
constructor
A new instance of List.
- #run ⇒ Object
- #update_if_necessary! ⇒ Object
Methods inherited from Pod::Command
#ensure_master_spec_repo_exists!, report_error, run
Methods included from Pod::Config::Mixin
Constructor Details
#initialize(argv) ⇒ List
Returns a new instance of List.
14 15 16 17 18 |
# File 'lib/cocoapods/command/list.rb', line 14 def initialize(argv) @update = argv.flag?('update') @stats = argv.flag?('stats') super end |
Class Method Details
.options ⇒ Object
7 8 9 10 11 12 |
# File 'lib/cocoapods/command/list.rb', line 7 def self. [ ['--update', 'Run `pod repo update` before listing'], ['--stats', 'Show additional stats (like GitHub watchers and forks)'], ].concat(super) end |
Instance Method Details
#run ⇒ Object
20 21 22 23 24 25 26 |
# File 'lib/cocoapods/command/list.rb', line 20 def run update_if_necessary! sets = SourcesManager.aggregate.all_sets sets.each { |set| UI.pod(set, :name_and_version) } UI.puts "\n#{sets.count} pods were found" end |