简体   繁体   English

如何整合两个 python 文件夹?

[英]How to integrate two python folders?

I have python located at two places in my OS(C:) drive.我的 python 位于我的 OS(C:) 驱动器的两个位置。

One is at [Folder1] C:\Python38一个位于 [Folder1] C:\Python38

Other is at [Folder2] C:\Users\User\AppData\Local\Programs\Python\Python38-32其他位于 [Folder2] C:\Users\User\AppData\Local\Programs\Python\Python38-32

Most of Folder1 and Folder2 are same, but when I run, say, pip install matplotlib , it shows some requirements satisfied in Folder1, while the others in Folder2.大多数 Folder1 和 Folder2 是相同的,但是当我运行pip install matplotlib时,它显示在 Folder1 中满足了一些要求,而在 Folder2 中满足了其他要求。

pip install matplotlib
Requirement already satisfied: matplotlib in c:\python38\lib\site-packages (3.2.1)
Requirement already satisfied: numpy>=1.11 in c:\python38\lib\site-packages (from matplotlib) (1.18.4)
Requirement already satisfied: pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=2.0.1 in c:\python38\lib\site-packages (from matplotlib) (2.4.7)
Requirement already satisfied: cycler>=0.10 in c:\python38\lib\site-packages (from matplotlib) (0.10.0)
Requirement already satisfied: kiwisolver>=1.0.1 in c:\python38\lib\site-packages (from matplotlib) (1.2.0)
Requirement already satisfied: python-dateutil>=2.1 in c:\python38\lib\site-packages (from matplotlib) (2.8.1)
Requirement already satisfied: six in c:\users\91860\appdata\roaming\python\python38\site-packages (from cycler>=0.10->matplotlib) (1.14.0)

However, I want all that in one place, so as to be able to delete either Folder1 or Folder2 to free up space.但是,我希望所有这些都在一个地方,以便能够删除 Folder1 或 Folder2 以释放空间。 How do i do that?我怎么做?

Looks like the one in C:\Users\User\AppData\Local... is 32-bit, while the one in C:\Python38 is the 64-bit version.看起来C:\Users\User\AppData\Local...中的那个是 32 位的,而C:\Python38中的那个是 64 位版本。

I would recommend uninstalling both, and doing a clean install.我建议将两者都卸载,然后进行全新安装。

If you don't want to remove both, I would recommend removing one of them from your PATH variables, and see if everything works fine.如果您不想同时删除两者,我建议您从 PATH 变量中删除其中一个,看看是否一切正常。

Keep in mind there are 2 options in the installer, one is for all users(will put python in program files folder) and the other one is per user (will be in users local appdata)请记住,安装程序中有两个选项,一个是针对所有用户的(将 python 放在程序文件夹中),另一个是针对每个用户的(将在用户本地 appdata 中)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM