[英]VS Code: How to set WSL2 terminal to virtual environment?
I'm setting up a virtual environment for a project, which I did without much trouble using the command prompt terminal.我正在为一个项目设置一个虚拟环境,我使用命令提示符终端没有太多麻烦。 However, if I open a second terminal but this time with Ubuntu (WSL2), it doesn't even have the same Python version.
但是,如果我打开第二个终端,但这次使用 Ubuntu (WSL2),它甚至没有相同的 Python 版本。 Probably it has to do with the virtualization of Ubuntu, but I'd like to know how can I have both terminals using the same virtual environment?
可能与 Ubuntu 的虚拟化有关,但我想知道如何让两个终端使用相同的虚拟环境?
Pictures for reference:图片供参考:
I am afraid it's impossible.恐怕这是不可能的。
In the first picture, you had got into the Linux system, so you can not take advantage of the python environment which in the windows system.在第一张图片中,您已经进入了 Linux 系统,因此您无法利用 windows 系统中的 python 环境。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.