Class: Whiskey::Command::Build

Inherits:
Object
  • Object
show all
Extended by:
Forwardable
Defined in:
lib/whiskey/command/build.rb

Constant Summary collapse

RUBIES =
["rbx", "jruby", "ruby-2.0.0"]
RUBIES_ASK =
"Which Ruby do you want to use?\n\n\t- ruby-2.0.0\n\t- rubinius\n\t- jruby\n"

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(command, name) ⇒ Build

Returns a new instance of Build.



19
20
21
22
# File 'lib/whiskey/command/build.rb', line 19

def initialize(command, name)
  @command = command
  @name = @command.values.name = name
end

Instance Attribute Details

#commandObject (readonly)

Returns the value of attribute command.



9
10
11
# File 'lib/whiskey/command/build.rb', line 9

def command
  @command
end

#nameObject (readonly)

Returns the value of attribute name.



9
10
11
# File 'lib/whiskey/command/build.rb', line 9

def name
  @name
end

Instance Method Details

#callObject



24
25
26
27
28
29
30
31
32
# File 'lib/whiskey/command/build.rb', line 24

def call
  create_root
  setup_root
  setup_server
  setup_db
  setup_ruby
  run("git init")
  say("You should now run: bundle install")
end