2017-03-07 23:10:32 +08:00
|
|
|
#!/usr/bin/env python
|
2012-03-22 06:29:32 +08:00
|
|
|
import os
|
|
|
|
import sys
|
2011-02-13 09:56:12 +08:00
|
|
|
|
2005-12-06 13:53:31 +08:00
|
|
|
if __name__ == "__main__":
|
2011-10-13 13:56:15 +08:00
|
|
|
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "{{ project_name }}.settings")
|
2016-03-20 07:49:06 +08:00
|
|
|
try:
|
|
|
|
from django.core.management import execute_from_command_line
|
2017-01-22 09:02:00 +08:00
|
|
|
except ImportError as exc:
|
|
|
|
raise ImportError(
|
|
|
|
"Couldn't import Django. Are you sure it's installed and "
|
|
|
|
"available on your PYTHONPATH environment variable? Did you "
|
|
|
|
"forget to activate a virtual environment?"
|
|
|
|
) from exc
|
2011-10-13 13:56:15 +08:00
|
|
|
execute_from_command_line(sys.argv)
|