Why Need to solve this issue.
So I Just Want to Use pipenv but do not want my venv
folder to built in my automatically decided location and also want to use pipenv
automatically building the requirements
list.
So For Resolving this issue I build a method of how to do that.
Straight to the Point The Steps are given below.
Create Virtual Environment normally with venv
module
For Windows
py -3 -m venv venv_folder
For Linux or Mac Operating System
python -m venv venv_folder
or
python3 -m venv venv_folder
Activate the manually created virtual environment folder
For Windows
# for windows powershell
./venv_folder/Scripts/Activate.ps1
# for windows cmd
./venv_folder/Scripts/activate.bat
# for windows with posix shell like git bash cli
source venv_folder/Scripts/activate
For Linux Based operating system or MacOS
source venv_folder/bin/activate
if you have any issues activating the venv please refer below post
![shriekdj](https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F776627%2F4d2559d8-851e-4207-a708-9da5d9ba3136.png)
How to create and Activate the Virtual Environment for Python3 project.
Shrikant Dhayje ・ Jan 19 '22
![shriekdj](https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F776627%2F4d2559d8-851e-4207-a708-9da5d9ba3136.png)
Python venv or virtualenv won't activate on windows Powershell
Shrikant Dhayje ・ Jan 18 '22
Install pipenv twice
Install the pipenv like given below
pip install pipenv
pipenv install pipenv
Courtesy Notice: Pipenv found itself running within a virtual environment, so it will automatically use that environment, instead of creating its own for any project. You can set PIPENV_IGNORE_VIRTUALENVS=1 to force pipenv to ignore that environment and create its own instead. You can set PIPENV_VERBOSITY=-1 to suppress this warning.
Installing pipenv...
...
Now install packages with pipenv as normal
You will now have pipenv and venv_folder both at the same time to run it.
Top comments (0)