Exciting release!Introducing "safe npm". Learn more
Socket
Log inDemoInstall

umzug-cli

Package Overview
Dependencies
3
Maintainers
1
Versions
10
Issues
File Explorer

Advanced tools

umzug-cli

A cli factory for umzug, a migration library

    3.1.1latest
    GitHub

Version published
Maintainers
1
Weekly downloads
228
decreased by-42.13%

Weekly downloads

Changelog

Source

v3.1.1

3.1.1 (2022-03-21)

Bug Fixes

  • Do not log table when there are no migrations executed (72d4ec8)

Readme

Source

umzug-cli

A cli factory for umzug, a migration library.
Umzug now has a built-in library. So the use of this module is discouraged.

Usage

  1. Create a executable migrate.js
#!/usr/bin/env node const KnexUmzug = require('knex-umzug') require('umzug-cli')({ storage: new KnexUmzug({ connection: knex({}) }), migrations: { glob: './migrations/*.js' } }).cli(process.argv.slice(2))
  1. Execute migrate.js
$ ./migrate.js Use: umzug-cli [command] Where [command] is one of: up migrates everything up down migrates 1 migration down up [file-to-migrate] migrates a specific file up down [file-to-migrate] migrates a specific file down pending shows all pending migrations history shows the migration history

Why doesn't this library offer an executable?

Because most likely each implementation has a custom config structure. This library directly uses umzug, which you can configure like documented https://www.npmjs.com/package/umzug#configuration

Keywords

FAQs

Last updated on 21 Mar 2022

Did you know?

Socket installs a Github app to automatically flag issues on every pull request and report the health of your dependencies. Find out what is inside your node modules and prevent malicious activity before you update the dependencies.

Install Socket
Socket
support@socket.devSocket SOC 2 Logo

Product

  • Package Issues
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc