No project description provided
Project description
simple-migrations (beta)
Please, notice that the library is early in the development, use it at your own risk. 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.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file simple_migrations-0.1.0.tar.gz
.
File metadata
- Download URL: simple_migrations-0.1.0.tar.gz
- Upload date:
- Size: 4.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.12.0 Darwin/22.6.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e9e9803197babbb09e893cac8a5688efa3ebfa590a047e4cac37221fab872c76 |
|
MD5 | 7f6f5dbfa6d3c0e01f7f2d4a229a7dd5 |
|
BLAKE2b-256 | 3ae3dcd4542830f21d61c37ee06abdf36c00efa3ca50fce20b9dee457f6d24e0 |
File details
Details for the file simple_migrations-0.1.0-py3-none-any.whl
.
File metadata
- Download URL: simple_migrations-0.1.0-py3-none-any.whl
- Upload date:
- Size: 6.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.12.0 Darwin/22.6.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d3b0b2760bdfcb101c237450265d034d00e6665494dca20bb4d21c26763ea1af |
|
MD5 | 5739690341b1f5e2105eb781a116689a |
|
BLAKE2b-256 | cb22353dee303ed0dd40d83c5f4aefa82c47ab9975e57d1deee4cecde2cc7bcb |