Class: GrapePress::Cli

Inherits:
Thor
  • Object
show all
Includes:
Configuration, Files, Tree, Thor::Actions
Defined in:
lib/grape_press/cli.rb

Instance Attribute Summary

Attributes included from Configuration

#active_record, #api_version, #app_class, #app_name, #database, #mongoid, #serializer

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.source_rootObject



14
15
16
# File 'lib/grape_press/cli.rb', line 14

def self.source_root
  File.dirname(__FILE__)
end

Instance Method Details

#destroy(name) ⇒ Object



26
27
28
# File 'lib/grape_press/cli.rb', line 26

def destroy(name)
  remove_dir name.underscore
end

#new(name) ⇒ Object



19
20
21
22
23
# File 'lib/grape_press/cli.rb', line 19

def new(name)
  collect(name)
  generate_tree
  generate_files
end