ankane/multiverse

Define db path

scottrobertson opened this issue · 2 comments

Hey

We have our migrations stored in a totally separate folder (it's actually a shared gem used by multiple apps), and we overwrite this with normal migrations by doing:

config.paths['db/migrate'] = ["#{Gem.loaded_specs['shared_gem'].full_gem_path}/db/migrate"]
config.paths['db'] = ["#{Gem.loaded_specs['shared_gem'].full_gem_path}/db"]

I cannot see a way to do this with multiverse. Is there?

Hey @scottrobertson, added support for config.paths['db'] on master. Multiverse determines the migrate path from the db path when a DB is specified (essentially #{config.paths['db']}/#{ENV["DB"]}/migrate), so config.paths['db/migrate'] won't be used in that case.

Awesome, thank you very much @ankane