I've been playing with SubSonic's SimpleRepository, and it's awesome. However, I would like to know if there's an easy way to apply pending changes to a production system.
Previously, I used SubSonic 2's "Migrations" via a batch file; when I was ready to move to production, I'd just run all the pending migrations against the production server, and I'd be ready to go. Nice and simple.
The SimpleRepostitory takes more of a "run them when you need them" approach to migrations, but I don't want to leave that option on when in production.
Is there a way to get a list of pending changes? I know I could use something like SqlDiff, but since I had a working solution before, it'd be a shame to lose it...
Anyone?
If you use reflector you can easily find how SimpleRepository manages Migrations.
I haven't actually tried this code, but you could simply do the Migrations the same way the SimpleRepository does:
Here is the method in Reflector: (following the logic on how MigrateFromModel figures out what needs to change is left as an exercise for the reader :) )