Class: Gen

Inherits:
Object
  • Object
show all
Defined in:
lib/gen.rb,
lib/gen.rb

Overview

The base generator class. – TODO: add support for facets command. ++

Direct Known Subclasses

AppGen, FormGen, PartGen

Constant Summary collapse

Version =

The version.

'0.41.0'
LibPath =

Library path.

File.dirname(__FILE__)

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#generator_dirObject

Returns the value of attribute generator_dir.



30
31
32
# File 'lib/gen.rb', line 30

def generator_dir
  @generator_dir
end

Instance Method Details

#runObject

Perform the generator actions.



47
48
# File 'lib/gen.rb', line 47

def run
end

#setupObject

Setup the generator.



42
43
# File 'lib/gen.rb', line 42

def setup
end

#teardownObject

Shutdown the generator.



52
53
# File 'lib/gen.rb', line 52

def teardown
end

#usageObject

Dump usage information for this controller.



34
35
36
37
38
# File 'lib/gen.rb', line 34

def usage
  filename = File.join(@generator_dir, 'USAGE')
  puts "\n#{File.read(filename)}"
  exit 1
end