0.1.2 • Published 7 months ago

reset-db-mysql v0.1.2

Weekly downloads
-
License
MIT
Repository
github
Last release
7 months ago

reset-db-mysql

Reset a MySQL database to an empty state recreating it if needed.

Install

npm i -D reset-db-mysql

Usage

Configure the reset command in your package.json file:

{
  "scripts": {
    "db:reset": "reset-db-mysql"
  }
}

Configure the DATABASE_URL in your local .env variables:

DATABASE_URL="mysql://USER:PASSWORD@HOST:3306/DATABASE"

And run the command every time you want to reset and remove all the tables of the database:

npm run db:reset
0.1.2

7 months ago

0.1.1

1 year ago

0.1.0

2 years ago