# Generators

**URL:** <https://discuss.rubyonrails.org/t/generators/48340>\
**Category:** rubyonrails-talk\
**Created:** [January 4, 2010, 3:29pm UTC](https://discuss.rubyonrails.org/t/generators/48340 "2010-01-04T15:29:41Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![11155](https://avatars.discourse-cdn.com/v4/letter/1/d26b3c/32.png) [@11155](https://discuss.rubyonrails.org/u/11155)\
**Post date:** [January 4, 2010, 3:29pm UTC](https://discuss.rubyonrails.org/t/generators/48340/1 "2010-01-04T15:29:41Z")

</div>

Could anyone tell me (or link me to) the best place to learn about RoR Module Generators?

---

<div class="post-metadata">

**Author:** ![11155](https://avatars.discourse-cdn.com/v4/letter/1/d26b3c/32.png) [@11155](https://discuss.rubyonrails.org/u/11155)\
**Post date:** [January 4, 2010, 8:07pm UTC](https://discuss.rubyonrails.org/t/generators/48340/2 "2010-01-04T20:07:49Z")

</div>

Pale Horse wrote:

> Could anyone tell me (or link me to) the best place to learn about RoR Module Generators?

What do you want to know?

And what are you going to use them for? Unless they generate \*extremely\* skeletal code, generators are a bad thing. (See restful\_authentication for an example of how \*not\* to use generators.)

Best,

---

<div class="post-metadata">

**Author:** ![11155](https://avatars.discourse-cdn.com/v4/letter/1/d26b3c/32.png) [@11155](https://discuss.rubyonrails.org/u/11155)\
**Post date:** [January 5, 2010, 9:05am UTC](https://discuss.rubyonrails.org/t/generators/48340/3 "2010-01-05T09:05:14Z")

</div>

Marnen Laibow-Koser wrote:

> Pale Horse wrote:
> 
> > Could anyone tell me (or link me to) the best place to learn about RoR Module Generators?
> 
> What do you want to know?
> 
> And what are you going to use them for? Unless they generate \*extremely\* skeletal code, generators are a bad thing. (See restful\_authentication for an example of how \*not\* to use generators.)
> 
> Best, -- Marnen Laibow-Koser [http://www.marnen.org](http://www.marnen.org) marnen@marnen.org

One example that I often use is a News feature... I just want to know how I can build a generator and then, utilise it.

---

<div class="post-metadata">

**Author:** ![11155](https://avatars.discourse-cdn.com/v4/letter/1/d26b3c/32.png) [@11155](https://discuss.rubyonrails.org/u/11155)\
**Post date:** [January 5, 2010, 11:24am UTC](https://discuss.rubyonrails.org/t/generators/48340/4 "2010-01-05T11:24:09Z")

</div>

Pale Horse wrote: [...]

> One example that I often use is a News feature...

Bad example. A plugin would probably better here.

> I just want to know how I can build a generator and then, utilise it.

Again: don't unless you're sure that a plugin won't be the better choice.

Best,

---

<div class="post-metadata">

**Author:** ![Rein\_Henrichs](https://avatars.discourse-cdn.com/v4/letter/r/71c47a/32.png) [@Rein\_Henrichs](https://discuss.rubyonrails.org/u/Rein_Henrichs)\
**Post date:** [January 5, 2010, 6:37pm UTC](https://discuss.rubyonrails.org/t/generators/48340/5 "2010-01-05T18:37:30Z")

</div>

Rails comes with a number of generators (see the output of `script/ generate` for more information). None of them, however, are "Module Generators", so your question is impossible to answer as asked. A module is a Ruby thing, not a Rails thing. Perhaps you can be more specific as to what you want to generate or what goal you are trying to accomplish?
