Configuring Python virtualenv in the window environment

Source: Internet
Author: User

What is virtualenv

Virtualenv is used to create multiple standalone Python runtime environments on a single machine, enable isolation of third-party package dependencies between projects, and enable rapid copy deployment of the development environment to the production environment.

Installing Virtualenv

Command line execute easy_install virtualenv, or download the source package yourself for installation

Create a new environment

1. Command line execution virtualenv D:\Python-Test (establish python-test independent environment in D disk), in the establishment of an independent environment, will rely on the site packages in the system environment, if you want to completely do not rely on the system of packages, You need to add a parameter--no-site-packages

2. The directory structure of the newly created environment is as follows


Start stop new environment

1. The command line enters D:\Python-Test\Scripts and executes active to start the new environment. The command line will have a (python-test) identity at the front of the boot success

2. The command line enters D:\Python-Test\Scripts and executes deactive to stop the new environment

Install the package in a new environment

1. Command line to start the new environment

2. Online Installation: Enter D:\Python-Test\Scripts and perform pip install Package_name

3. Offline Installation: Unpack the package to a directory and enter the directory to execute the python setup.py install


This address: http://blog.csdn.net/fragmentalice/article/details/44833251

Configuring Python virtualenv in the window environment

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.