What does " -r " do in pip install -r requirements.txt What does " -r " do in pip install -r requirements.txt python python

What does " -r " do in pip install -r requirements.txt


Instead of pip --help, look into pip install --help:

-r, --requirement Install from the given requirements file. This option can be used multiple times.

Also see these documentation paragraphs:


-r will search for requirement file.

pip install --help

will help you !!


In your case pip install -r requirements.txt will install the libraries listed in your requirements.txt file.