Class: SinatraBootstrap::Stage
- Inherits:
-
Thor
- Object
- Thor
- SinatraBootstrap::Stage
- Includes:
- Thor::Actions
- Defined in:
- lib/sinatra_bootstrap/stage.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.source_root ⇒ Object
7 8 9 |
# File 'lib/sinatra_bootstrap/stage.rb', line 7 def self.source_root File.join File.dirname(__FILE__), 'templates' end |
Instance Method Details
#heroku ⇒ Object
35 36 37 38 39 40 41 42 43 44 |
# File 'lib/sinatra_bootstrap/stage.rb', line 35 def heroku copy_file 'Gemfile-heroku', 'Gemfile' copy_file 'config.ru' copy_file 'Procfile' copy_file 'main.rb' always_restart if [:pow] say 'Simple development startup:' say ' bundle install' say ' foreman start' end |
#sinatra ⇒ Object
20 21 22 23 24 25 26 27 28 |
# File 'lib/sinatra_bootstrap/stage.rb', line 20 def sinatra copy_file 'Gemfile-bare', 'Gemfile' copy_file 'config.ru' if [:rackup] always_restart if [:pow] copy_file 'main.rb' say 'Simple startup:' say ' bundle install' say ' ruby ./main.rb' end |