From c0b4a0e3c7b3c9b1a6e4f4395cd88489479784e0 Mon Sep 17 00:00:00 2001 From: Kenneth Reitz <me@kennethreitz.com> Date: Wed, 18 Jan 2012 12:45:47 -0500 Subject: [PATCH] collectstatic #25 --- bin/steps/django | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/bin/steps/django b/bin/steps/django index cb6dbb35..74cce91e 100755 --- a/bin/steps/django +++ b/bin/steps/django @@ -1,5 +1,5 @@ #!/usr/bin/env bash -echo "-----> Django settings injection" +echo "-----> Injecting Django settings..." SETTINGS_FILE=$(ls **/settings.py | head -1) PROJECT=$(dirname $SETTINGS_FILE) @@ -46,3 +46,14 @@ except Exception: print 'Unexpected error:', sys.exc_info() EOF + + +# Compile assets. +echo "-----> Collecting static files" +python $PROJECT/manage.py collectstatic --noinput | indent + +[ $? -ne 0 ] && { + echo " ! Error running manage.py collectstatic. See http://devcenter.heroku.com/articles/django-assets for more info." +} + +set -e -- GitLab