git hook to reload database on checkout when schema changes -


our database schema generated programmatically files in our /models directory. i'd figure out git hook can use when doing checkout or merge, compare sha1 of /models directory, , if not same had before, re-initialize test database , reload our fixtures.

is possible lookup sha1 of /models directory, save in variable, , compare results after completing checkout/merge?

thanks in advance pointers.

for rails, guard-migrate decent solution operates @ different level git. monitors db/schema.rb changes, , updates database if necessary. sure turn off while working on writing migrations.


Comments

Popular posts from this blog

java - Jmockit String final length method mocking Issue -

asp.net - Razor Page Hosted on IIS 6 Fails Every Morning -

c++ - wxwidget compiling on windows command prompt -