Starting your social website project

Open the terminal, and use the following commands to create a virtual environment for your project and activate it:

mkdir envvirtualenv env/bookmarkssource env/bookmarks/bin/activate

The shell prompt will display your active virtual environment, as follows:

(bookmarks)laptop:~ zenx$

Install Django in your virtual environment with the following command:

pip install Django==2.0.5

Run the following command to create a new project:

django-admin startproject bookmarks

After creating the initial project structure, use the following commands to get into your project directory and create a new application named account:

cd bookmarks/django-admin startapp account

Remember that you should activate the new application ...

Get Django 2 by Example now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.