Skip to main content

Add one command to reset the migrations of one or more app

Project description

License PyPI Downloads

Django reset migrations

Add one command to reset the django migrations.

Sometimes you have one app that had a lot migrations in development process. And this migrations could be deleted, because anybody will need this in the future.

Soo, could be stressfull delete the files, reset the database and create the first migration again … to start to developer again and bla bla bla …

Because this, I made this command to reset the migrations and start the first migration.

I hope be usefull to you 2 :D

Features

  • delete migrations files
  • delete registers in django_migrations
  • recreate the first migrations
  • apply fake migration
  • delete register without delete files with –cached

To install

pip install django-reset-migrations

Install package in your INSTALLED_APPS

settings.py

INSTALLED_APPS = (
    ...
    'reset_migrations',
    .....
)

Usage

python manage.py reset_migrations crm

or

python manage.py reset_migrations app1 app2

or

python manage.py reset_migrations app1 app2 --cached

Options

–cached: Don´t delete the migrations files in apps

Project details


Download files

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

Files for django-reset-migrations, version 0.4.0
Filename, size File type Python version Upload date Hashes
Filename, size django-reset-migrations-0.4.0.macosx-10.14-x86_64.tar.gz (4.7 kB) File type Dumb Binary Python version any Upload date Hashes View hashes
Filename, size django_reset_migrations-0.4.0-py3-none-any.whl (8.0 kB) File type Wheel Python version 3.7 Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page