django project setup

Quick steps to setup Django Project

👣 Steps to Follow

   

  • You will need
    • Windows 10 or later
    • Python 3.6 or later
    • pip (python Package Manager)

 

  1. Open a Terminal (run as Administrator)
  2. Check Python and Pip is Installed Or Not
    1. python3 –version
      • if not then install Python
    2. upgrade Pip to the Latest Version with this command
      • python -m pip install –upgrade pip
  3. Create a Project Directory
    1. cd desktop
    2. mkdir django_project
  4. Create a Virtual Environment
    1. pip install pipenv
    2. Navigate to the Project Location
  5. Activiate the Virtual Environment
    1. pipenv shell  (to activate Virtual Environment or to create a new one)
  6. Install Django in that Virtual Environment
    1. pipenv install django
  7. Create a Django Project
    1. django-admin startproject project_name
  8. Run the Development Server
    1. python manage.py runserver
    2. Agar port change karna he to 
      1. python manage.py runserver 8001 (desired port)
  •