Simple script creating migrations for MySQL databases. If you have a pleasure to use legacy frameworks that didn't have their own migration scripts - feel free to use.
- Bash
- MySQL client
- Clone
- Put your SQL files to
queries
directory - Copy
config.sh.dist
toconfig.sh
- Set your database credentials in
config.sh
you can change migrations table name as well - Run script
./migrate.sh
To create new query file you can use create.sh
script, e.g.: ./create.sh add-sample-column
will make new sql file with actual date and your task name given as parameter
Enjoy!