Registry / database / bkn-migration

bkn-migration

JSON →
library1.0.6jsnpmunverified

A database migration CLI tool for MySQL databases, currently at version 1.0.6. It allows executing named migration files (referred to as 'rgr' in the documentation) against a specified database. The configuration is done via a YAML file (mg-config.yaml) in the project root, specifying database connection details and folder path for migration scripts. It supports optional automatic Git push after migration. This package is simple, globally installed, and designed for a specific workflow with MySQL.

npm install bkn-migration
INSTALL
IMPORT
SIG · BKN-MIGRATION
B
bkn-migration
databasejavascriptv1.0.6
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Demonstrates global installation, configuration file setup, and basic usage of the migration CLI.

# Install globally npm install --global bkn-migration # Create mg-config.yaml in project root with content: # db: # host: localhost # user: UserName # password: secret # port: 3306 # path: # folder: data # Run migration for database named 'mydb' with migration set 'initial' migration mydb initial # Run migration and push to Git (current branch) migration mydb initial git
Debug
Known issues
gotchaThe configuration file must be named 'mg-config.yaml' and placed in the project root directory. Other names or locations will not be recognized.
fix
Rename your config file to 'mg-config.yaml' and ensure it's in the root of your project.
affects: >=1.0.0
gotchaThe 'git' parameter enables automatic Git commit and push; it uses the current branch. Ensure the user is authenticated with Git before using this option, or it may fail silently.
fix
Before running with 'git', verify your git credentials and that the current branch is correct.
affects: >=1.0.0
gotchaThe second positional argument is required and must be a valid migration set name (referred to as 'rgr'). Running without it will result in a usage error.
fix
Always provide a database name and a migration set name. Example: 'migration mydb initial'.
affects: >=1.0.0
Upgrade
Version history
1.0.6latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
13 hits · last 30 days
node
12
OpenAI (training)
1
Resources
bkn-migration — npm install bkn-migration · libregistry