Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

manage.py not present in Django project

Tags:

python

django

I'm just starting the Django tutorial. On running the command:

$django-admin.py startproject mysite

the mysite project is created, but there's no manage.py file under mysite/

I tried to get the verbose output:

$django-admin.py startproject -v 3 mysite 
/home/pratik/Source/Numerical/ETS/etsproxy/enthought/__init__.py:7: DeprecationWarning: enthought namespace imports are deprecated
  DeprecationWarning)
Rendering project template files with extensions: .py
Rendering project template files with filenames: 
Creating /home/pratik/Projects/django_learn/mysite/mysite/__init__.py
Creating /home/pratik/Projects/django_learn/mysite/mysite/urls.py
Creating /home/pratik/Projects/django_learn/mysite/mysite/settings.py
Creating /home/pratik/Projects/django_learn/mysite/mysite/wsgi.py

I'm using the latest Django source from the git repository

Any ideas on what might be wrong? I'll update this post with more information as I go along.

More Information:

$ python
Python 2.6.6 (r266:84292, Dec 26 2010, 22:31:48) 
[GCC 4.4.5] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> 

Edit: It seems that manage.py is just a wrapper around django-admin.py, so now I can at least go ahead with the tutorial

Edit2: I tried with the stable 1.4.3 version as well, but still no luck

$ django-admin.py version
1.4.3

Edit3: Here is the output of tree:

$ tree
.
`-- mysite
    `-- mysite
        |-- __init__.py
        |-- settings.py
        |-- urls.py
        `-- wsgi.py

2 directories, 4 files
like image 723
pratikm Avatar asked Jan 27 '13 18:01

pratikm


1 Answers

can you just create your manage.py manually?

put this code inside:

#!/usr/bin/env python
import os
import sys

if __name__ == "__main__":

    os.environ.setdefault("DJANGO_SETTINGS_MODULE", "{{ project_name }}.settings")

    from django.core.management import execute_from_command_line

    execute_from_command_line(sys.argv)

source: https://github.com/django/django/blob/master/django/conf/project_template/manage.py

like image 70
Eyal Ch Avatar answered Oct 15 '22 22:10

Eyal Ch