Python Galery
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

manage.py 624B

123456789101112131415161718192021
  1. #!/usr/bin/env python
  2. """Django's command-line utility for administrative tasks."""
  3. import os
  4. import sys
  5. def main():
  6. os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'main.settings')
  7. try:
  8. from django.core.management import execute_from_command_line
  9. except ImportError as exc:
  10. raise ImportError(
  11. "Couldn't import Django. Are you sure it's installed and "
  12. "available on your PYTHONPATH environment variable? Did you "
  13. "forget to activate a virtual environment?"
  14. ) from exc
  15. execute_from_command_line(sys.argv)
  16. if __name__ == '__main__':
  17. main()