How do I use Django for another project?

I am trying to start a project using Django. I used Django once, and now I would like to use it again, but this time in a different folder. I keep getting stuck in the terminal trying to execute the commands to install Django. This is what I keep on seeing.

$ pip install pipenv
Defaulting to user installation because normal site-packages is not writeable
Requirement already satisfied: pipenv in c:\users\shawonne shann\appdata\roaming\python\python313\site-packages (2025.0.3)
Requirement already satisfied: certifi in c:\users\shawonne shann\appdata\roaming\python\python313\site-packages (from pipenv) (2025.6.15)
Requirement already satisfied: packaging>=22 in c:\users\shawonne shann\appdata\roaming\python\python313\site-packages (from pipenv) (25.0)
Requirement already satisfied: setuptools>=67 in c:\users\shawonne shann\appdata\roaming\python\python313\site-packages (from pipenv) (80.9.0)
Requirement already satisfied: virtualenv>=20.24.2 in c:\users\shawonne shann\appdata\roaming\python\python313\site-packages (from pipenv) (20.31.2)
Requirement already satisfied: distlib<1,>=0.3.7 in c:\users\shawonne shann\appdata\roaming\python\python313\site-packages (from virtualenv>=20.24.2->pipenv) (0.3.9)
Requirement already satisfied: filelock<4,>=3.12.2 in c:\users\shawonne shann\appdata\roaming\python\python313\site-packages (from virtualenv>=20.24.2->pipenv) (3.18.0)
Requirement already satisfied: platformdirs<5,>=3.9.1 in c:\users\shawonne shann\appdata\roaming\python\python313\site-packages (from virtualenv>=20.24.2->pipenv) (4.3.8)
Shawonne Shann@Latitude-E5450 MINGW64 /c/codingprojects/selfpace/selfpacefolder
$ pipenv install django
bash: pipenv: command not found

What should I do

You installed pipenv globally for your user but you're using Git Bash which doesn't see user installed Python packages in PATH.

Fix (run in git bash):

bashpython -m pipenv install django

This uses python to run pipenv directly no PATH issue, then start your project:

bashpython -m pipenv shell
django-admin startproject myproject

Well, depending on the python version you use, you should set up a venv environment and install all your packages (including Django) in there again. Every time you want to run your Django project, you activate the venv (some IDEs may do this automatically). Here are the docs: https://docs.python.org/3/library/venv.html.

Вернуться на верх