Wrapper grunt task for the node-migrate module. Very handy if you are going to need a generic interface for your migrations and want to automate them.
Want to see pretty graphs? Log in now!
npm install grunt-migrate
|2||downloads in the last week|
|16||downloads in the last month|
|Last Published By|
|Version||0.0.1 last updated 10 months ago|
There are a few handy small migration modules running around on npm. This module will let you interface with them using grunt. I use grunt for build automation and like everything done in the same place.
grunt migrate:create --name <name of migration>
Running the above task will create a migration folder and a file named 001-.js. Running this migration is as simple as
migration:up without an argument will run all migration files to the HEAD. You can also optionally specify a specific
migration to use as a ceiling.
grunt migration:up --name 002-somefile.js
Specifying an argument means that it will stop when it reaches that file.
If you want to migrate down the syntax is the same
grunt migration:down --name 001-somefile.js
===================================================================== This plugin is using the module: https://github.com/visionmedia/node-migrate
But there are many others that without much work would also easily integrate.