Ensure you have the following installed on your system:
- Python (>=3.x)
- Git
- pip (comes with Python)
- Virtual environment (
venv)
git clone https://github.com/your-username/your-repo.git
cd your-repopython3 -m venv .venv
source .venv/bin/activatepython -m venv .venv
.venv\Scripts\activatepython -m venv .venv
.venv\Scripts\Activate.ps1pip install -r requirements.txtpython manage.py migratepython manage.py runserverYour Django project will now be running at:
http://127.0.0.1:8000/
If your project has Django Admin, create a superuser:
python manage.py createsuperuserFollow the prompts to set up login credentials.
- Deactivate Virtual Environment:
deactivate
- Install Additional Packages:
pip install package-name pip freeze > requirements.txt
- If you get a
ModuleNotFoundError, ensure the virtual environment is activated. - If the database is not working, run:
python manage.py makemigrations python manage.py migrate
You're all set! 🎉 Happy coding!