0.0.10 • Published 5 years ago

dbdelta v0.0.10

Weekly downloads
33
License
-
Repository
-
Last release
5 years ago

DBDelta

Database migrations done differently.

Overview

DBDelta is inpspired heavily by migra, for an excellent description of the concept while these docs are under development please take a look there.

Installation

npm install -g dbdelta

or

yarn global add dbdelta

Usage

All DBDelta commands take an optional --database argument, which defaults to the enironment variable DATABASE_URL.

Show the current schema

dbdelta schema

Synchronise schema

Reads a set of SQL files stored on disk and synchronises the database. Pass --show to see the SQL changes, and --commit to keep the synchronised changes. Also accepts --base <path> to specify where to find the SQL schema files (defaults to the current directory).

dbdelta schema --show --commit --base ./db

Make migrations

Creates a new migration file to carry out the necessary changes to synchonise the database. Accepts the same argumets as sync, with the addtion of --migrations <path> which specifies where to place the new migraiton.

dbdelta make --show --commit --base ./db --migrations ./db/migrations

Migrate database

Migrates the current database using made migrations. TODO

dbdelta make --base ./db --migrations ./db/migrations
0.0.10

5 years ago

0.0.9

5 years ago

0.0.8

5 years ago

0.0.7

5 years ago

0.0.6

5 years ago

0.0.5

5 years ago

0.0.4

5 years ago

0.0.3

5 years ago

0.0.2

5 years ago

0.0.1

5 years ago

0.0.0

5 years ago