From: Jan Szejko Date: Fri, 8 Dec 2017 15:52:57 +0000 (+0100) Subject: honor the dont-repackage option in republish X-Git-Url: https://git.mdrn.pl/edumed.git/commitdiff_plain/f2ad2e35dec5c6109256e8ef8d70ad874a0c9ec4?ds=inline;hp=bab0a9769a853e7b7d6368e293838be1bef4a8f6 honor the dont-repackage option in republish --- diff --git a/catalogue/management/commands/republish.py b/catalogue/management/commands/republish.py index 12ee480..48f9345 100644 --- a/catalogue/management/commands/republish.py +++ b/catalogue/management/commands/republish.py @@ -39,7 +39,8 @@ class Command(BaseCommand): print '!!!!!! PARSE ERROR !!!!!!' print e - print 'Rebuilding levels...' - for level in Level.objects.all(): - print level.name - level.build_packages() + if options.get('repackage'): + print 'Rebuilding levels...' + for level in Level.objects.all(): + print level.name + level.build_packages()