Class: Pod::Command::Repo::List

Inherits:
Pod::Command::Repo show all
Defined in:
lib/cocoapods/command/repo.rb

Overview

———————————————————————–#

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Pod::Command::Repo

#branch_name, #branch_remote_name, #dir, #url_of_git_repo

Methods included from Executable

#executable, execute_command

Methods inherited from Pod::Command

parse, report_error, run, verify_git_version!

Methods included from Pod::Config::Mixin

#config

Constructor Details

#initialize(argv) ⇒ List

Returns a new instance of List.



202
203
204
205
# File 'lib/cocoapods/command/repo.rb', line 202

def initialize(argv)
  @count_only = argv.flag?('count-only')
  super
end

Class Method Details

.optionsObject



198
199
200
# File 'lib/cocoapods/command/repo.rb', line 198

def self.options
  [["--count-only", "Show the total number of repos"]].concat(super)
end

Instance Method Details

#runObject



218
219
220
221
222
# File 'lib/cocoapods/command/repo.rb', line 218

def run
  sources = SourcesManager.all
  print_sources(sources) unless @count_only
  print_count_of_sources(sources)
end