Module

Commands

There's no documentation for this item.

Classes
Base Generator commands delegate Rails::Generator::Base and implement a standard set of actions. Their behavior is defined by the way they respond to these actions: Create brings life; Destroy brings death; List passively observes.
Create Create is the premier generator command. It copies files, creates directories, renders templates, and more.
Destroy Undo the actions performed by a generator. Rewind the action manifest and attempt to completely erase the results of each action.
List List a generator’s action manifest.
RewindBase Base class for commands which handle generator actions in reverse, such as Destroy.
Update Update generator’s action manifest.
Public Methods
included Even more convenient access to commands. Include Commands in the generator Base class to get a nice #command instance method which returns a delegate for the requested command.
instance Here’s a convenient way to get a handle on generator commands. Command.instance(‘destroy’, my_generator) instantiates a Destroy delegate of my_generator ready to do your dirty work.
Comments

Have your say
Please use Textile formatting (click here for a cheat sheet). Use <code/> and <pre/> for code samples.
Click here to login with OpenID to to post comments.