`pip freeze` can be useful for this kind of thing On Thu, 17 Feb 2022 at 18:19, Chris Angelico <[email protected]> wrote:
> On Fri, 18 Feb 2022 at 13:12, Vishesh Mangla <[email protected]> > wrote: > > > > Consider the following scenario: > > 1) You have to format your pc. > > 2) You copy your python projects to your hard disk along with the > virtual environment(I keep the virtual environment in the project folder > only). > > 3)When you copy your projects back after successfully formatting your > pc, the useless virtualenv lies there and you can't get the > requirements.txt now and have to install all packages one by one. > > > > It could be great if pip or python or anyone would by default store a > requirements.txt file inside the virtual env and on `pip install xyz` > would append `xyz` to that file. > > > > OR! You maintain your own requirements.txt manually, and always use > 'pip install -r requirements.txt' when you change it. That works much > better with source control. > > ChrisA > _______________________________________________ > Python-ideas mailing list -- [email protected] > To unsubscribe send an email to [email protected] > https://mail.python.org/mailman3/lists/python-ideas.python.org/ > Message archived at > https://mail.python.org/archives/list/[email protected]/message/YNU3D2FH6L75DLHTQS4A7Q7EV6UVYOCM/ > Code of Conduct: http://python.org/psf/codeofconduct/ >
_______________________________________________ Python-ideas mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/[email protected]/message/VRVU3OL2RY6TXKKXKYG2NYTZXYZVOI5O/ Code of Conduct: http://python.org/psf/codeofconduct/
