Django (a)---install Django

Source: Internet
Author: User
Tags install django virtual environment

Prepare the virtual environment: Python Development Virtual Environment

Pre-Installation Preparation1. Download Django:django DownloadThis article uses the django-1.5.9 (the difference between different versions is still relatively large, do not make a mistake)
2. Prepare the Django project directory: Define a directory yourself as the project directory
my own preparation is: ~/DJANGO15
3. About Virtual Environments3.1 Create
Mkvirtualenv DJANGO15
Automatically jumps to the virtual environment when createdYou can also manually enter a virtual environment:
Workon DJANGO15
The effect is the same
when your command-line prompt becomes similar to the following:
(DJANGO15) terminal_user> $

it means that the next operation is done in a virtual environment. # #当进入虚拟环境中后, it's much easier to operate, and it isolates the development environment (that is, the virtual environment) from the system environment, without "polluting" the system's Python environment!

Note# #接下来的安装操作没有特殊说明, all in a virtual environment# #虚拟环境中, the previous commands on Linux are fully applicable! namely: CD, LS and other commands are fully applicableInstalling DjangoDecompression django-1.5.9.tar.gzEnter django-1.5.9 Execution:
Python setup.py Install

Django is installed, and you can see that Django is installed in a virtual environment.
to the project directory you created earlier, that is:~/django15 Create a project, you can also call the site:
django-admin.py Startproject MySite

A MySite site is created here.

Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

Django (a)---install Django

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.