Reusing previous code

Hi,

I have a couple of controllers, views, models and mailers for a given
functionality (for example, user registration). ¿what is the best way to
share them between multiple applications so that I don’t have to copy
them
over and over again?

Thanks.

On 10/08/06, Matias S. [email protected] wrote:

I have a couple of controllers, views, models and mailers for a given
functionality (for example, user registration). ¿what is the best way to
share them between multiple applications so that I don’t have to copy them
over and over again?

Put the functionality in an engine and include this engine and the
engines plugin[1] in every app that uses it.

Cheers,
Hasan D. [email protected]

  1. http://rails-engines.org/wiki/pages/Engines+plugin