Sign Up for Free

RunKit +

Try any Node.js package right in your browser

This is a playground to test code. It runs a full Node.js environment and already has all of npm’s 400,000 packages pre-installed, including migr8r with all npm packages installed. Try it out:

var migr8r = require("migr8r")

This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.

migr8r v1.0.0

Easily run Postgres migrations using SQL files

migr8r

Easily run Postgres migrations using SQL files

oclif Version CircleCI Appveyor CI Codecov Downloads/week License

* [Usage](#usage) * [Commands](#commands) # Usage ```sh-session $ npm install -g migr8r $ migr8r COMMAND running command... $ migr8r (-v|--version|version) migr8r/1.0.0 linux-x64 node-v10.5.0 $ migr8r --help [COMMAND] USAGE $ migr8r COMMAND ... ``` # Commands * [`migr8r help [COMMAND]`](#migr-8-r-help-command) * [`migr8r migrate`](#migr-8-r-migrate) * [`migr8r migrate:create NAME`](#migr-8-r-migratecreate-name) * [`migr8r run [PATH]`](#migr-8-r-run-path)

migr8r help [COMMAND]

display help for migr8r

USAGE
  $ migr8r help [COMMAND]

ARGUMENTS
  COMMAND  command to show help for

OPTIONS
  --all  see all commands in CLI

See code: @oclif/plugin-help

migr8r migrate

Run .sql files

USAGE
  $ migr8r migrate

OPTIONS
  -c, --connectionString=connectionString
  -d, --dir=dir                            [default: .]
  -h, --help                               show CLI help

EXAMPLE
  $ migr8r migrate
  Migrating...

See code: src/commands/migrate.ts

migr8r migrate:create NAME

Create a migration .sql file

USAGE
  $ migr8r migrate:create NAME

ARGUMENTS
  NAME  The name of the migration to create.

OPTIONS
  -d, --dir=dir  [default: .]
  -h, --help     show CLI help

EXAMPLE
  $ migr8r migrate:create add-user-table
  Creating migration: 2018-01-01-01-01-01-add-user-table.sql

See code: src/commands/migrate/create.ts

migr8r run [PATH]

Run .sql files

USAGE
  $ migr8r run [PATH]

OPTIONS
  -c, --connectionString=connectionString
  -h, --help                               show CLI help

EXAMPLE
  $ migr8r run path/to/file.sql
  Running...

See code: src/commands/run.ts

RunKit is a free, in-browser JavaScript dev environment for prototyping Node.js code, with every npm package installed. Sign up to share your code.
Sign Up for Free