A CLI to generate typeorm migrations from an exist mysql database
git clone https://github.com/salesplay/mytypeorm.git
cd mytypeorm
yarn -D
To generate migrations of all tables.
yarn cli all --host 127.0.0.1 --port 3306 --username root --password \
my_password --output-directory ./migrations
To generate a migration of a specific table.
yarn cli child --host 127.0.0.1 --port 3306 --username root --password \
my_password --output-directory ./migrations --child-name "table_name"
- Unique Indexes
- Primary Indexes
- Enums
- Foreign keys
All PRs and issues are welcome.
This tool is made for a specific use case. So this tool has limited features. Do not hesitate to open an issue if you want a new feature request. We will implement your feature ASAP.