{"repo":"why2pac/knex-automigrate","free":true,"listed":false,"github":"https://github.com/why2pac/knex-automigrate","clone":"git clone https://github.com/why2pac/knex-automigrate.git","description":"Table schema based database migration tool, built on top of the knex.js","language":"TypeScript","stars":10,"topics":["nodejs","knexjs","database","orm","table","migration"],"license":"MIT","category":"databases-storage","readme_excerpt":"knex-automigrate ================ Table schema based database migration tool, built on top of knex.js. Define your table schema once and let knex-automigrate handle CREATE, ALTER, and DROP operations automatically — no numbered migration files needed. - Written in TypeScript with full type declarations included - Migration schema file name must start with table or view - Currently supported dialects for index migration: mysql , mysql2 Installation For CLI usage (global install): Usage Before (traditional database migration with knex.js) Migration files are, After (database migration with knex-automigrate) Migration files are named with table or view prefix. The prefix determines whether the file defines table schemas or view schemas. Migration files are, Simply edit the schema file and run migrate:auto again — columns are added, altered, or dropped automatically to match the definition. CLI Programmatic Usage TypeScript Options Option Type Description -------- ------ ------------- config Knex.Config & { safe?: boolean } Knex configuration. Set safe: true to prevent dropping columns. cwd string Directory to scan for table .js / view .js migration files. verbose boolean Enable/disable console output. Default: true . tables (migrator, knex) = MigrationEntry[] Inline table definitions (in addition to file-based). views (migrator, knex) = MigrationEntry[] Inline view definitions (in addition to file-based). Supported index types How it works 1. Reads the current table schema from ","default_branch":null,"files":null,"tree":[],"storefront":"/r/why2pac","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/why2pac/knex-automigrate/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}