Class: Sinatra::ConsoleCommand

Inherits:
EnvCommand show all
Defined in:
lib/sinatra/commands/console_command.rb

Instance Attribute Summary

Attributes inherited from EnvCommand

#args, #env

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from EnvCommand

inherited, #initialize

Methods inherited from Command

#app_path, #cmd, commands, inherited, #rm, #rm_r, #template_path

Constructor Details

This class inherits a constructor from Sinatra::EnvCommand

Class Method Details

.commandObject



4
5
6
# File 'lib/sinatra/commands/console_command.rb', line 4

def self.command
  "console"
end

.helpObject



8
9
10
# File 'lib/sinatra/commands/console_command.rb', line 8

def self.help
  "[environment]\t\t# default: development"
end

Instance Method Details

#callObject



12
13
14
15
# File 'lib/sinatra/commands/console_command.rb', line 12

def call
  path = app_path("setup.rb")
  cmd "pry -r #{path}"
end