6 ms·
> I have no idea why you wouldn't want the database change scripts/functions/schema to be stored in git, alongside the application code. I couldn't agree more.
by nbouscal 13y ago
> I have no idea why you wouldn't want the database change scripts/functions/schema to be stored in git, alongside the application code.
I couldn't agree more. It boggles my mind how many people are resistant to storing this stuff in version control. It is code! Treat it like code! The exact same thing applies to configuration management. Your chef cookbooks should live in your git repository right next to your application code, and right next to your database code. That's the only possible way for every node in your source history graph to be functional in isolation. If your database changes independently of your version control, you simply cannot check out an arbitrary commit and expect anything to work.