Class: Gemstash::CLI::Setup
Overview
This implements the command line setup task:
$ gemstash setup
Instance Method Summary collapse
-
#initialize(cli) ⇒ Setup
constructor
A new instance of Setup.
- #run ⇒ Object
Constructor Details
#initialize(cli) ⇒ Setup
Returns a new instance of Setup.
10 11 12 13 |
# File 'lib/gemstash/cli/setup.rb', line 10 def initialize(cli) super @config = {} end |
Instance Method Details
#run ⇒ Object
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
# File 'lib/gemstash/cli/setup.rb', line 15 def run if setup? && !@cli.[:redo] @cli.say @cli.set_color("Everything is already setup!", :green) return end check_rubygems_version ask_storage ask_cache ask_database check_cache check_storage check_database store_config @cli.say @cli.set_color("You are all setup!", :green) end |