Dependency links for extras_require in setup.py
I searched way too long to figure out how to do this with setup.cfg so hopefully this will help someone else if they don't want to use setup.py as the OP didn't specify. I've also included a custom URL for install_requires as that took a while to figure out as well.
#setup.cfg (only showing relevant parts)
[options]
install_requires =
pyyaml @ git+https://github.com/yaml/pyyaml.git@master
[options.extras_require]
jsonschema = jsonschema @ git+https://github.com/Julian/[email protected]
six = six
pip install -e .[jsonschema]
will get you the extra with a custom URL orpip install -e .[jsonschema,six]
will get you both extras (note that there are NO spaces after the.
or around the comma(s) in the extras list).- As far as I can tell, you cannot get extras installed using
python setup.py install
. - Yes
--process-dependency-links
is still deprecated in spite of much complaining but the above is good enough once you know the syntax.