Hi Chris,
I've just joined this google group. am a long time CF developer and
recently had a taste of rails on a 3 month project, so when I found
out about CF on wheels, it was a perfect fit for me. Love what you
guys are doing with this project, and would like to contribute back to
it where possible. Not sure if anyone is interested but I recently
wrote a database migration script in CF similar to ActiveRecord
migrations (rake db:migrate).
The migration files are called via a single script migrate.cfm?
version=x and look something like:-
<cfcomponent extends="migration" output="false">
<cffunction name="up" returntype="void" access="public"
hint="migrates up">
<cfscript>
t = newTable('authors');
t.string(columnNames='firstName,lastName',limit=100);
t.boolean(columnNames='active',default=true,null=false);
t.create();
</cfscript>
</cffunction>
<cffunction name="down" returntype="void" access="public"
hint="migrates down">
<cfscript>
dropTable('authors');
</cfscript>
</cffunction>
</cfcomponent>
There are functions for all the different data types and a references
command for creating foreign keys and columns using wheels
conventions.
Is this something you would be interested in including into wheels at
some stage, perhaps alongside other "rake" scripts? Currently it runs
as a stand-alone CF application but perhaps it could be incorporated
into the wheels application itself or as a plugin.
Personally I've found database migrations great when working as a team
using SVN, as you can checkin your database structure changes in the
same version as the code they relate to. Plus it makes updating test
and production databases so much easier.
A "contributing to wheels" chapter would definitely be helpful. As I
said before, love your work on this project and am looking forward to
version 0.8. Am glad there's an active community working on CF wheels.
cheers
Ryan