Class: Pod::Command::Binary::Fetch
- Inherits:
-
Pod::Command::Binary
- Object
- Pod::Command
- Pod::Command::Binary
- Pod::Command::Binary::Fetch
- Defined in:
- lib/command/fetch.rb
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(argv) ⇒ Fetch
constructor
A new instance of Fetch.
- #run ⇒ Object
Methods inherited from Pod::Command::Binary
#load_podfile, #prebuild_config, #update_cli_config
Constructor Details
#initialize(argv) ⇒ Fetch
Returns a new instance of Fetch.
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/command/fetch.rb', line 15 def initialize(argv) super unless ENV['ARTIFACTORY_LOGIN'].nil? && ENV['ARTIFACTORY_PASSWORD'].nil? update_cli_config( :artifactory_login => ENV['ARTIFACTORY_LOGIN'], :artifactory_password => ENV['ARTIFACTORY_PASSWORD'] ) else Pod::UI.puts "Enter Artifactory login:" login = IO::console.gets.strip Pod::UI.puts "Enter Artifactory password:" password = IO::console.getpass update_cli_config( :artifactory_login => login, :artifactory_password => password ) end update_cli_config( :fetch_job => true ) @fetcher = PodPrebuild::CacheFetcher.new( config: prebuild_config, repo_update: argv.flag?("repo-update") ) end |
Class Method Details
.options ⇒ Object
9 10 11 12 13 |
# File 'lib/command/fetch.rb', line 9 def self. [ ["--repo-update", "Update pod repo before installing"] ].concat(super) end |
Instance Method Details
#run ⇒ Object
41 42 43 |
# File 'lib/command/fetch.rb', line 41 def run @fetcher.run end |