mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2024-11-11 12:17:37 +03:00
23 lines
305 B
Plaintext
23 lines
305 B
Plaintext
|
#!/usr/bin/env bash
|
||
|
|
||
|
compress_enabled() {
|
||
|
python << END
|
||
|
import sys
|
||
|
|
||
|
from environ import Env
|
||
|
|
||
|
env = Env(COMPRESS_ENABLED=(bool, True))
|
||
|
if env('COMPRESS_ENABLED'):
|
||
|
sys.exit(0)
|
||
|
else:
|
||
|
sys.exit(1)
|
||
|
|
||
|
END
|
||
|
}
|
||
|
|
||
|
if compress_enabled
|
||
|
then
|
||
|
python manage.py compress
|
||
|
fi
|
||
|
python manage.py collectstatic --noinput
|