modifiying existing files in your template script

Ok, so I just started digging into template files using the command

rails mynewprojectname -m templatescript.rb

and it's really, really awesome 8)

What I want to do is something like this in my script -

generate(:scaffold, "user name:string")
# add some code into the scaffold generate model and controller here!

Essentially, I would like my template script to populate my scaffold
generated files with some default code so I don't have to type the
same things over and over again. Make sense? As an example, by the
time my template is done, it'd be nice to have a bunch of models up
and running with all their associations set up.

From what I've read about templates, it seems like this should be
feasible, but all i've seen so far is some template snippets for
extending ruby's object class to add some methods like not_nil?, which
is great, but not quite what I'm looking for :slight_smile:

Thanks for taking the time to look at this!