Question

I installed django 1.5.1 with PIP.

I am trying to learn Django, and tried to make a test project.

When I run pip freeze, it returns Django==1.5.1 as one of my installed packages.

When I run django-admin.py startproject test_project it returns, -bash: django-admin.py: command not found.

I cannot start this test project. Any advice as to how I can start a new django project?

I am on a Mac OSX 10.5.8.

Was it helpful?

Solution

I found the solution on this page.

I was able to solve my path issue by running:

sudo ln -s /usr/local/lib/python2.7/site-packages/django/bin/django-admin.py /usr/local/bin/django-admin.py

This created a "Permission Denied" error though. I was able to solve that issue by running:

sudo chmod +x /usr/local/bin/django-admin.py

django-admin.py is now working.

OTHER TIPS

I have used follwong command to install (/usr/local/bin)

pip install django

django-admin startproject mysite
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top