2024-03-28 11:43:18 发布
网友
我很难设置python包。来自SetupTools的EasyInstall应该会有帮助,但它们没有Python 2.6的可执行文件。
例如,要安装Mechanize,我只需要根据install.txt将Mechanize文件夹放在C:\Python24\Lib\site包中,但是运行测试不起作用。有人能帮我解释一下吗?谢谢!
This是如何在windows上获得easy_install的好教程。简单的答案是:在路径中添加C:\Python26\Scripts(或安装的任何python)。
easy_install
C:\Python26\Scripts
accepted answer已经过时。所以首先,^{}比easy_install,(Why use pip over easy_install?)更受欢迎。然后按照以下步骤在Windows上安装pip,这非常简单。
pip
安装^{}:
curl https://bootstrap.pypa.io/ez_setup.py | python
curl https://bootstrap.pypa.io/get-pip.py | python
也可以将路径添加到环境中,以便可以在任何地方使用pip。它就在C:\Python33\Scripts这样的地方。
C:\Python33\Scripts
较新版本的Python for Windows附带了pip包管理器。(source)
pip is already installed if you're using Python 2 >=2.7.9 or Python 3 >=3.4
使用它安装软件包:
cd C:\Python\Scripts\ pip.exe install <package-name>
所以你的情况是:
pip.exe install mechanize
This是如何在windows上获得
easy_install
的好教程。简单的答案是:在路径中添加C:\Python26\Scripts
(或安装的任何python)。accepted answer已经过时。所以首先,^{} 比
easy_install
,(Why use pip over easy_install?)更受欢迎。然后按照以下步骤在Windows上安装pip
,这非常简单。安装^{} :
安装^{} :
也可以将路径添加到环境中,以便可以在任何地方使用
pip
。它就在C:\Python33\Scripts
这样的地方。较新版本的Python for Windows附带了pip包管理器。(source)
使用它安装软件包:
所以你的情况是:
相关问题 更多 >
编程相关推荐