Class Uttk::Generators::Generator
In: lib/uttk/generators/generator.rb
Parent: Rails::Generator::NamedBase

Methods

dir_name   new  

Classes and Modules

Module Uttk::Generators::Generator::Rails
Class Uttk::Generators::Generator::DirSource
Class Uttk::Generators::Generator::Manifest

Attributes

email  [R] 
fullname  [R] 
root  [R] 
year  [R] 

Public Class methods

[Source]

# File lib/uttk/generators/generator.rb, line 27
      def initialize ( runtime_args, runtime_options={} )
        @fullname = ENV['FULLNAME'] || raise('The FULLNAME environement variable is not set')
        @email = ENV['EMAIL'] || raise('The EMAIL environement variable is not set')
        @root = __FILE__.to_path.dirname.parent.parent.parent.expand_path.cleanpath
        @year = Time.now.year
        super(runtime_args,
              { :destination => @root.to_s }.merge!(runtime_options))
        @root = '.'.to_path
      end

Public Instance methods

[Source]

# File lib/uttk/generators/generator.rb, line 44
      def dir_name
        module_name.to_s.underscore
      end

[Validate]