I know that I can create a wheel by first writing a setup.py
and then typing
python setup.py bdist_wheel
If my wheels depend only on packages in pypi I know that I can install them by doing:
pip install mypkg.whl
Question: if my wheels depend on other of my wheels, can I have pip automatically install them from a folder? Essentially using a folder as a poor man's private pypi
To be more specific, if in pkg1
I have a setup.py
:
from setuptools import setup
setup(
...
name = "pkg1",
install_requires = ["requests"],
...
)
And in pkg2
I have:
from setuptools import setup
setup(
...
name = "pkg2",
install_requires = ["pkg1"],
...
)
This will fail on installation because pip will try to look for pkg1
in pypi. Is it possible to tell it to just look in a folder?
pip install --find-links /path/to/wheel/dir/ pkg2
If you want to completely disable access to PyPI add --no-index
:
pip install --no-index --find-links /path/to/wheel/dir/ pkg2
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