| 1 |
|
| 2 |
"""Django's command-line utility for administrative tasks.""" |
| 3 |
|
| 4 |
import os |
| 5 |
import sys |
| 6 |
|
| 7 |
|
| 8 |
def main(): |
| 9 |
"""Run administrative tasks.""" |
| 10 |
os.environ.setdefault( |
| 11 |
"DJANGO_SETTINGS_MODULE", "tests.demo_project.multi_param.settings" |
| 12 |
) |
| 13 |
try: |
| 14 |
from django.core.management import execute_from_command_line |
| 15 |
except ImportError as exc: |
| 16 |
raise ImportError( |
| 17 |
"Couldn't import Django. Are you sure it's installed and " |
| 18 |
"available on your PYTHONPATH environment variable? Did you " |
| 19 |
"forget to activate a virtual environment?" |
| 20 |
) from exc |
| 21 |
execute_from_command_line(sys.argv) |
| 22 |
|
| 23 |
|
| 24 |
if __name__ == "__main__": |
| 25 |
main() |