From d7f969613ef4f12a8d22f8bddd742be8762ca6a6 Mon Sep 17 00:00:00 2001 From: Oliver Walters Date: Sun, 8 Sep 2019 20:45:01 +1000 Subject: [PATCH] Update makefile and docs --- Makefile | 6 ++++-- docs/update.rst | 8 +++++++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 91a604ebd9..38446635da 100644 --- a/Makefile +++ b/Makefile @@ -7,8 +7,10 @@ clean: rm -rf .tox rm -f .coverage +update: backup migrate + # Perform database migrations (after schema changes are made) -migrate: backup +migrate: python3 InvenTree/manage.py makemigrations common python3 InvenTree/manage.py makemigrations company python3 InvenTree/manage.py makemigrations part @@ -64,4 +66,4 @@ backup: python3 InvenTree/manage.py dbbackup python3 InvenTree/manage.py mediabackup -.PHONY: clean migrate superuser install mysql style test coverage docreqs docs backup \ No newline at end of file +.PHONY: clean migrate superuser install mysql style test coverage docreqs docs backup update \ No newline at end of file diff --git a/docs/update.rst b/docs/update.rst index d6ef6a5913..d3266b4126 100644 --- a/docs/update.rst +++ b/docs/update.rst @@ -29,7 +29,13 @@ Perform Migrations Updating the database is as simple as calling the makefile target: -``make migrate`` +``make update`` + +This command performs the following steps: + +* Backup database entries and uploaded media files +* Perform required database schema changes +* Collect required static files Restart Server --------------