Class: Faststrap::Bootstrap
- Inherits:
-
Thor
- Object
- Thor
- Faststrap::Bootstrap
- Includes:
- Thor::Actions
- Defined in:
- lib/faststrap.rb
Instance Method Summary collapse
Instance Method Details
#clean ⇒ Object
52 53 54 55 56 57 58 59 60 61 62 63 64 |
# File 'lib/faststrap.rb', line 52 def clean Faststrap::InstallActions.load_default_actions if Faststrap::InstallActions.list_installed.empty? puts "You dont have any faststrap tools installed".yellow else puts "All the tools that will be uninstalled:" Faststrap::InstallActions.list_installed.each{|e| puts e.name.yellow} answer = yes?("Are you sure?".red) Faststrap::InstallActions.list_installed.map{|a| a.uninstall} if answer end end |
#ios ⇒ Object
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 |
# File 'lib/faststrap.rb', line 27 def ios puts "We have the follow actions for ios :" Faststrap::InstallActions.load_default_actions install_actions = Faststrap::InstallActions.list ag = Faststrap::ActionsGroup [ag::INSTALLERS,ag::COMAND_LINE,ag::TESTS,ag::CI].map do |g| Faststrap::InstallActions.present(g) end everything = [:all] if everything puts "Installing everything .." Faststrap.handle_answer('*',install_actions) else answer = ask("\nType the actions you want to install separated by comma (eg. git,xctool)\n or type * for everything :") answer = answer.include?("*") ? "*" : answer.split(',') Faststrap.handle_answer(answer,install_actions) end end |