Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

simple-migrations

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

simple-migrations

  • 0.3.0
  • PyPI
  • Socket score

Maintainers
1

simple-migrations (beta)

PyPI version Python versions

The feedback and contributions are appreciated!

Make your database migrations as simple as possible!

simple-migrations is a library that allows you to write database migrations in a pure SQL.

The order of migrations will be tracked in the database table.

You can specify the forwards and backwards command and even write your own scripts.

No need to apply the scripts manually, you can now automate your deployment flow!

Keep in mind that the library is still in development and is distributed "as is".

How to use

The example of the config can be found in simple_migrations.ini file.

Create a simple_migrations.ini file in the project root and set up the database credentials.

Run simple-migrations init to generate the migrations directory and migrations table.

Run simple-migrations generate to generate the migration file from the template.

Run simple-migrations migrate to apply all unapplied migrations.

Run simple-migrations migrate <num> to migrate or rollback to migration, for example:

  • If the last applied migration was #2, simple-migrations migrate 4 will apply migrations 3 and 4.
  • If the last applied migration was #4, simple-migrations migrate 2 will rollback migrations 3 and 4.

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc