使用PyCharm从GitHub安装Python包 [英] Install Python package from GitHub using PyCharm
问题描述
我在PyCharm中创建了一个VirtualEnv来安装我的Python包。我想从GitHub安装django项目的这个分支。
I created a VirtualEnv in PyCharm to install my Python packages. I wanted to install this fork of the django project from GitHub.
https://github.com/django-nonrel/django
对于 PyPI 我通常会在PyCharm中使用内置的搜索工具,但我不确定如何从GitHub正确安装到PyCharm中的VirtualEnv中。有人会知道如何做到这一点吗?
For packages available from PyPI I would normally use the built in search tool in PyCharm but I'm not sure how to correctly install it into the VirtualEnv within PyCharm from GitHub. Would anyone know how to do this?
推荐答案
我个人建议将资源库克隆到本地文件夹中。
$ b
I personally would suggest cloning the repository to a local folder
git clone https://github.com/django-nonrel/django.git my_folder
然后手动安装:
Then install it manually:
cd my_folder
python setup.py build
python setup.py install
我不推荐使用PyCharm安装软件包,因为你会变得依赖它...
使用pip来代替,这是pycharm使用的工具
I wouldn't recommend using PyCharm to install the packages, since you will become dependent on it... Use pip instead, wich is the tool pycharm uses anyway
这篇关于使用PyCharm从GitHub安装Python包的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!