2.0.1 • Published 9 months ago

@tibormarias/quickgrate v2.0.1

Weekly downloads
-
License
ISC
Repository
github
Last release
9 months ago

Quickgrate

A fast and easy way to copy and seed one MySQL database to another

What does it do?

Quickgrate copies table stuctures and table contents from a master database to a slave database. I use it in order to have production data in my dev environments for real world testing purposes. Be careful, it deletes existing tables on slave!

Installation

Install the package

npm install @tibormarias/quickgrate --save-dev

Create a file named quickgrate.config.js in your project's root directory with the following structure

module.exports = {
    master: {
        host: "127.0.0.1",
        port: "3306",
        user: "user",
        password: "pass",
        database: "production",
    },
    slave: {
        host: "127.0.0.1",
        port: "3306",
        user: "user",
        password: "pass",
        database: "development"
    },
    rows_limit: 25000,
    tables: {
        do_not_create: [],
        do_not_seed: []
    }
}

Running the script

npx quickgrate

Optional flags

--changes only remove and seed tables that are different on slave then on master

Development

Want to contribute? I am grateful for any contribution, feel free to code it or message me!

1.2.0

9 months ago

1.1.6

9 months ago

1.1.5

9 months ago

1.2.3

9 months ago

1.1.4

9 months ago

1.2.2

9 months ago

1.1.3

9 months ago

1.2.1

9 months ago

2.0.1

9 months ago

2.0.0

9 months ago

1.1.2

1 year ago

1.1.1

1 year ago

1.1.0

1 year ago

1.0.9

1 year ago

1.0.8

1 year ago

1.0.7

1 year ago

1.0.6

1 year ago

1.0.4

1 year ago

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago