[Erector-devel] rails generators (the second)

Brian Takita brian.takita at gmail.com
Wed Apr 8 23:57:02 EDT 2009


On Tue, Apr 7, 2009 at 6:25 PM, Alex Chaffee <alex at pivotallabs.com> wrote:
> A couple of points:
>
> * I am strongly *against* splitting Erector into two gems. As I said a few
> days ago: "My opinion on this is that it doesn't hurt to check out code that you
> don't need and never require, but it hurts a lot to have two projects
> with potentially diverging version numbers and mutual support
> matrices. So I'd like to keep rails support in the main library,
> inside a subdirectory &c where it doesn't hurt anybody who doesn't use
> it."
I think multiple gems worth considering.
One big problem with supporting multiple versions of Rails is there
are multiple definitions of the same method, due to how difficult it
is to integrate with Rails.

I really like Jeff's idea with only supporting one version of Rails in
the main Erector gem.

I would like to submit the idea of having a n (including one)
additional Erector gems to support backward compatibility.

Another idea is to encourage users to fork Erector for the version of
Rails they are trying to support.
Hopefully, Erector's codebase can be further simplified and be easy to
understand with good extension points.

I can start different forks of Erector which I will infrequently merge
with master. The beauty of Git is, if somebody really cares about
being up-to-date, they can create a fork off of their fork of choice.
It is then easy to merge in changes with the master branch in the
pivotal/erector project.

To me, the fork idea is the more compelling one.
>
> * Generators make me feel kind of weird -- generated code can get
> stale fast, much faster than library code that sits behind a clean API
> -- but given that Rails already uses it I suppose I can't complain if
> someone writes an Erector scaffold generator. When I wrote 'erect' I
> thought I could make it work well enough that you could just run it on
> Rails-generated RHTML but right now you need to do a lot of cleanup
> after you run it, maybe too much to make it a recommendable option.
> Even in a perfect world you'd have to do some cleanup.
>
> ---
> Alex Chaffee - alex at stinky.com
> Stalk me: http://friendfeed.com/alexch | http://twitter.com/alexch |
> http://alexch.tumblr.com
>


More information about the Erector-devel mailing list