Class: SimpleSinatraApi::CLI
- Inherits:
-
Thor::Group
- Object
- Thor::Group
- SimpleSinatraApi::CLI
- Includes:
- Thor::Actions
- Defined in:
- lib/simple_sinatra_api/cli.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.source_root ⇒ Object
11 12 13 |
# File 'lib/simple_sinatra_api/cli.rb', line 11 def self.source_root File.('../../../templates', __FILE__) end |
Instance Method Details
#create_app ⇒ Object
18 19 20 |
# File 'lib/simple_sinatra_api/cli.rb', line 18 def create_app directory 'new_app', name.underscore end |
#initialize_git_repo ⇒ Object
22 23 24 25 26 |
# File 'lib/simple_sinatra_api/cli.rb', line 22 def initialize_git_repo inside(name.underscore) do run('git init .') end end |
#install_dependencies ⇒ Object
28 29 30 31 32 |
# File 'lib/simple_sinatra_api/cli.rb', line 28 def install_dependencies inside(name.underscore) do run('bundle') end end |