Home  >  Article  >  Backend Development  >  PyCharm creates virtualenv method

PyCharm creates virtualenv method

高洛峰
高洛峰Original
2016-11-22 12:55:111782browse

 PyCharm can use the functions in virtualenv to create virtual environments. PyCharm is tightly integrated with virtualenv, so you only need to configure it in the setting to create a virtual environment. And PyCharm bundles virtualenv, we don't need to install it separately. The general creation process is as follows:

1. Open the Project Interpreters page: File -> Settings - > Project - > Project Interpreters;

PyCharm creates virtualenv method

2. Select the project , click the configuration button on the right and select Create VirtualEnv. At this time, the Create Virtual Environment dialog box will pop up;

3. Configure the new environment:

Fill in the name of the new virtual environment in Name, or use the default name to facilitate future installation of third-party packages and other projects;

In Location Fill in the file directory of the new environment;

Select the Python interpreter in the Base interpreter drop-down box;

Check Inherit global site-packages to use third-party libraries in the base interpreter. If not, it will be completely isolated from the outside world;

Check Make available to all projects to make this virtual environment available to other projects.

4. Click OK and everything is configured. Isn't this much simpler than configuring virtualenv separately? ​

PyCharm creates virtualenv method

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Previous article:Python parses QR codeNext article:Python parses QR code