Class: Rails::Generators::NamedBase
Relationships & Source Files | |
Extension / Inclusion / Inheritance Descendants | |
Subclasses:
ActiveRecord::Generators::Base, ActiveRecord::Generators::MigrationGenerator, ActiveRecord::Generators::ModelGenerator, Css::Generators::AssetsGenerator, Css::Generators::ScaffoldGenerator, Erb::Generators::Base, Erb::Generators::ControllerGenerator, Erb::Generators::MailerGenerator, Erb::Generators::ScaffoldGenerator, Js::Generators::AssetsGenerator, Rails::Generators::AssetsGenerator, Rails::Generators::ControllerGenerator, Rails::Generators::GeneratorGenerator, Rails::Generators::HelperGenerator, Rails::Generators::IntegrationTestGenerator, Rails::Generators::JobGenerator, MailerGenerator, Rails::Generators::MigrationGenerator, Rails::Generators::ModelGenerator, Rails::Generators::ResourceGenerator, Rails::Generators::ResourceRouteGenerator, Rails::Generators::ScaffoldControllerGenerator, Rails::Generators::ScaffoldGenerator, Rails::Generators::TaskGenerator, TestUnit::Generators::Base, TestUnit::Generators::ControllerGenerator, TestUnit::Generators::GeneratorGenerator, TestUnit::Generators::HelperGenerator, TestUnit::Generators::IntegrationGenerator, TestUnit::Generators::JobGenerator, TestUnit::Generators::MailerGenerator, TestUnit::Generators::ModelGenerator, TestUnit::Generators::PluginGenerator, TestUnit::Generators::ScaffoldGenerator
|
|
Super Chains via Extension / Inclusion / Inheritance | |
Class Chain:
self,
Base,
Thor::Group
|
|
Instance Chain:
|
|
Inherits: |
Rails::Generators::Base
|
Defined in: | railties/lib/rails/generators/named_base.rb |
Class Method Summary
Base - Inherited
.base_root | Returns the base root for a common set of generators. |
.default_source_root | Returns the default source root for a given generator. |
.desc | Tries to get the description from a USAGE file one folder above the source root otherwise uses a default description. |
.hide! | Convenience method to hide this generator from the available ones when running rails generator command. |
.hook_for | Invoke a generator based on the value supplied by the user to the given option named “name”. |
.namespace | Convenience method to get the namespace from the class name. |
.remove_hook_for | Remove a previously added hook. |
.source_root | Returns the source root for this generator using default_source_root as default. |
Instance Method Summary
Actions - Included
#add_source | Add the given source to |
#after_bundle | Registers a callback to be executed after bundle and spring binstubs have run. |
#application | Alias for Actions#environment. |
#capify! | Just run the capify command in root. |
#environment | Adds a line inside the ::Rails::Application class for |
#gem | Adds an entry into |
#gem_group | Wraps gem entries inside a group. |
#generate | Generate something using a generator from ::Rails or a plugin. |
#git | Run a command in git. |
#initializer | Create a new initializer with the provided code (either in a block or a string). |
#lib | Create a new file in the lib/ directory. |
#rake | Runs the supplied rake task. |
#rakefile | Create a new |
#readme | Reads the given file at the source root and prints it in the console. |
#route | Make an entry in ::Rails routing file |
#vendor | Create a new file in the |