Class: HappySeed::Cli
- Inherits:
-
Thor
- Object
- Thor
- HappySeed::Cli
- Defined in:
- lib/happy_seed/cli.rb
Instance Method Summary collapse
- #engine(*args) ⇒ Object
- #plugin(*args) ⇒ Object
- #rails(*args) ⇒ Object
- #static(name) ⇒ Object
- #static_blog(name) ⇒ Object
Instance Method Details
#engine(*args) ⇒ Object
18 19 20 21 22 |
# File 'lib/happy_seed/cli.rb', line 18 def engine( *args ) require 'generators/happy_seed/plugin/plugin_generator' ARGV << "--mountable" HappySeed::Generators::PluginGenerator.start end |
#plugin(*args) ⇒ Object
12 13 14 15 |
# File 'lib/happy_seed/cli.rb', line 12 def plugin( *args ) require 'generators/happy_seed/plugin/plugin_generator' HappySeed::Generators::PluginGenerator.start end |
#rails(*args) ⇒ Object
6 7 8 9 |
# File 'lib/happy_seed/cli.rb', line 6 def rails( *args ) seedrb = gem_file_path( "happy_seed.rb") system "rails new -m #{seedrb} #{args.join( " " )} --skip-turbolinks" end |
#static(name) ⇒ Object
25 26 27 28 |
# File 'lib/happy_seed/cli.rb', line 25 def static( name ) require 'generators/happy_seed/static/static_generator' HappySeed::Generators::StaticGenerator.start end |
#static_blog(name) ⇒ Object
31 32 33 34 |
# File 'lib/happy_seed/cli.rb', line 31 def static_blog( name ) require 'generators/happy_seed/static_blog/static_blog_generator' HappySeed::Generators::StaticBlogGenerator.start end |