I'm making a setup.py that needs to point to my repository.
with github i can do this:
dependency_links=['https://github.com/nathanborror/django-registration/tarball/master#egg=django-registration']
how can I do the same with a bitbucket project ?
for example this url:
https://bitbucket.org/abraneo/django-registration
Thanks.
pip is a standard package manager used to install and maintain packages for Python. The Python standard library comes with a collection of built-in functions and built-in packages. Data science packages like scikit-learn and statsmodel are NOT part of the Python standard library.
You can deploy Git locally, or use it via a hosted service, such as Github, Gitlab or Bitbucket. One of the advantages of using pip together with Git is to install the latest commits of unreleased Python packages as branches from Github.
Install the downloaded package into a local directory : python get-pip.py --user This will install pip to your local directory (. local/bin) . Now you may navigate to this directory (cd . local/bin) and then use pip or better set your $PATH variable this directory to use pip anywhere : PATH=$PATH:~/.
Your Github link looks to be pointing to a gzipped tar file. Try doing the same for your Bitbucket hosted project -- https://bitbucket.org/abraneo/django-registration/get/tip.tar.gz
A BitBucket Mercurial (hg) repository can be added with the following URL in dependency_links
:
'https://bitbucket.org/zzzeek/alembic/get/tip.zip#egg=alembic-0.6.0'
In this case it installs the development version (0.6) of the Alembic package, which is not yet in PyPI at the time of writing.
Note that BitBucket supports both Mercurial and git. if the repo is Mercurial, the URL must reference tip.zip
, but if it's git, the URL must reference master.zip
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With