How to point pip at a Mercurial branch?

前端 未结 1 507
别那么骄傲
别那么骄傲 2021-02-01 15:42

I\'m trying to install my application via pip to a virtualenv for testing.

Works fine for installing the default or tip like so:



        
相关标签:
1条回答
  • 2021-02-01 16:14

    In official pip documentation in section VCS Support:

    Mercurial

    The supported schemes are: hg+http, hg+https, hg+static-http and hg+ssh:

    -e hg+http://hg.myproject.org/MyProject/#egg=MyProject
    -e hg+https://hg.myproject.org/MyProject/#egg=MyProject
    -e hg+ssh://hg@myproject.org/MyProject/#egg=MyProject
    

    You can also specify a revision number, a revision hash, a tag name or a local branch name:

    -e hg+http://hg.myproject.org/MyProject/@da39a3ee5e6b#egg=MyProject
    -e hg+http://hg.myproject.org/MyProject/@2019#egg=MyProject
    -e hg+http://hg.myproject.org/MyProject/@v1.0#egg=MyProject
    -e hg+http://hg.myproject.org/MyProject/@special_feature#egg=MyProject
    

    The syntax is the same when specifying repo at the command line

    pip install -e hg+http://hg.myproject.org/MyProject/@special_feature#egg=MyProject
    

    and it works when not using -e option starting from version 0.8.2.

    0 讨论(0)
提交回复
热议问题