How can I install packages using pip according to the requirements.txt file from a local directory?

This works for everyone:

pip install -r /path/to/requirements.txt

Explanation:

-r, –requirement < filename >

Install from the given requirements file. This option can be used multiple times.

Leave a Comment