Skip to content

ucev/mysql-creator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mysql-creator

A simple mysql database generator tools for nodejs.

Database config files are written using yaml. See examples under test.

Install

node.js

  npm install mysql-creator --save

Usage examples

  1. create database
  ./bin/mysql_creator ${PATH_TO_CONFIG_FILE}
  1. import data
  ./bin/mysql_creator -h ${HOSTNAME} -u ${USERNAME} -d ${DBNAME} -i ${PATH_TO_DATA_FILE} -p
  1. export data
  ./bin/mysql_creator -h ${HOSTNAME} -u ${USERNAME} -d ${DBNAME} -o ${PATH_TO_OUTPUT_FILE} -p
  1. export database structure
  ./bin/mysql_creator -h ${HOSTNAME} -u ${USERNAME} -d ${DBNAME} -e ${PATH_TO_OUTPUT_FILE} -p

具体命令行参数的格式见 minimist

Params

  • -d: target database
  • -e: path to file where structure are exported
  • -h: mysql hostname
  • -i: path to file with data to import
  • -o: path to file where data are exported
  • -p: mysql password
  • -u: mysql username

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published