Flask extension to integrate Alembic migrations
Project description
This Flask extension provides a configurable Alembic migration environment around a Flask-SQLAlchemy database.
Installation
Install releases from PyPI:
pip install Flask-Alembic
Install the latest code from BitBucket:
pip install https://bitbucket.org/davidism/flask-alembic/get/default.tar.gz
Basic Usage
You’ve created a Flask application and some models with Flask-SQLAlchemy. Now start using Flask-Alembic:
from flask_alembic import Alembic # Intialize the extension alembic = Alembic() alembic.init_app(app) # Auto-generate a migration alembic.revision('making changes') # Upgrade the database alembic.upgrade() # Access the internals environment_context = alembic.env
Commands are included for Click (Flask 0.11, or Flask-CLI):
$ flask db revision "making changes" $ flask db upgrade
and Flask-Script:
$ python manage.py db --help
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
Flask-Alembic-2.0.1.tar.gz
(16.4 kB
view hashes)
Built Distribution
Close
Hashes for Flask_Alembic-2.0.1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7e67740b0b08d58dcae0c701d56b56e60f5fa4af907bb82b4cb0469229ba94ff |
|
MD5 | 79118df5e3be15e3f90c33ee95768dc6 |
|
BLAKE2b-256 | c4fc63f9bccffbde7c303fe2958e6b54b4cdf8e0cb94c37b197362e1ef860230 |