Skip to main content

A Django app to provide easy simultaneous migrations

Project description

Quick migrations via manage.py

When executed without arguments, it will search for the QUICK_MIGRATE setting in settings.py, make migrations for every app in it and apply them.

Otherwise, it will do the same only upon apps given as arguments.

Prompt py manage.py quickmigrate -h for more specific details on arguments or read the docs below.

Quickstart

Installation

  1. Open your Django project and activate virtual environment.

  2. After activating virtual environment install the package using pip install django-quickmigrate

  3. Open your settings.py and add 'quickmigrate' to your INSTALLED_APPS

  4. Add additional list QUICK_MIGRATE into your settings. It should look pretty much like INSTALLED_APPS, except you fill it only with apps you want to be migrated when you call py manage.py quickmigrate without arguments.

  5. And that's it. Now you can use quickmigrate in your project!

Additional arguments

Quickmigrate allows you to choose a variety of apps to migrate during one call.

You can manipulate this using additional arguments listed below:

  1. -i, --inst — command will look at your INSTALLED_APPS instead of QUICK_MIGRATE. In its turn, this flag takes one optional argument: either base or all (defaults to all).

    • base will just call makemigrations and migrate commands. As the result, only basic apps such as admin will be migrated.
    • all will make and apply migrations for all INSTALLED_APPS which support migrations.
  2. -a, --apps — command will look for specific apps. It can take any amount of arguments starting from 1.
    e.g. py manage.py quickmigrate --apps myapp1 myapp2 admin auth

With no arguments provided, the command will look in your QUICK_MIGRATE setting.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-quickmigrate-1b2.tar.gz (5.1 kB view details)

Uploaded Source

File details

Details for the file django-quickmigrate-1b2.tar.gz.

File metadata

  • Download URL: django-quickmigrate-1b2.tar.gz
  • Upload date:
  • Size: 5.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.56.2 CPython/3.9.0

File hashes

Hashes for django-quickmigrate-1b2.tar.gz
Algorithm Hash digest
SHA256 3579ba97e34d4a9eb4c38f47e168d7d1aba72ece99bc1278e9ec41bddf5604d9
MD5 a8f807d25f29237c5babe5e700f846ea
BLAKE2b-256 96bb2b20faa6d5adca772f20b33b811c659ba4eb115bca3a739a3aa88bb962fd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page