从 git repo 分支安装 pip [英] pip install from git repo branch

查看:41
本文介绍了从 git repo 分支安装 pip的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

尝试 pip 安装存储库的特定分支.Google 告诉我

Trying to pip install a repo's specific branch. Google tells me to

pip install https://github.com/user/repo.git@branch

分支的名称是 issue/34/oscar-0.6 所以我做了 pip install https://github.com/tangentlabs/django-oscar-paypal.git@/issue/34/oscar-0.6 但它返回 404.

The branch's name is issue/34/oscar-0.6 so I did pip install https://github.com/tangentlabs/django-oscar-paypal.git@/issue/34/oscar-0.6 but its returning a 404.

如何安装这个分支?

推荐答案

前置 url 前缀 git+(参见 VCS 支持):

Prepend the url prefix git+ (See VCS Support):

pip install git+https://github.com/tangentlabs/django-oscar-paypal.git@issue/34/oscar-0.6

并指定不带前导/的分支名称.

And specify the branch name without the leading /.

这篇关于从 git repo 分支安装 pip的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆