DEV Community

Cover image for Setup and use Virtualenv in Python Applications
Wesley Bertipaglia
Wesley Bertipaglia

Posted on

2 2 1 1 2

Setup and use Virtualenv in Python Applications

virtualenv is a simple to use tool to create isolated Python environments.

For more information visit: virtualenv documentation.

Installation:



pip install virtualenv


Enter fullscreen mode Exit fullscreen mode

Creating a Virtual Environment:



virtualenv <env_name>


Enter fullscreen mode Exit fullscreen mode

Activating the Virtual Environment:

  • On Unix-like systems (Unix, Linux, or MacOS): ```bash

source /bin/activate


- On Windows:
```bash


<env_name>\Scripts\activate


Enter fullscreen mode Exit fullscreen mode

Deactivating the Virtual Environment:



deactivate


Enter fullscreen mode Exit fullscreen mode

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay