By using the --extra option, users can add custom packages to the requirements.txt file, like so:
$ pipreqs --extra pipreqs,example
This command generates the correct file, alphabetized and all, including pipreqs and example (in this case).
This adds pipreqs itself and example to the requirements.txt file, as my original intention was to add pipreqs to the requirements.txt file. (I know there are severely easier ways to do so, but I implemented it anyway.)
I added the test_extra_module test, which it passed alongside all other tests; should be good to go!
By using the --extra option, users can add custom packages to the
requirements.txt
file, like so:$ pipreqs --extra pipreqs,example
This command generates the correct file, alphabetized and all, including pipreqs and example (in this case).This adds pipreqs itself and example to the
requirements.txt
file, as my original intention was to add pipreqs to therequirements.txt
file. (I know there are severely easier ways to do so, but I implemented it anyway.)I added the
test_extra_module
test, which it passed alongside all other tests; should be good to go!