Friday, September 3, 2021

Python update all component by PIP

1 c:\ pip freeze > requirements.txt

2 edit requirements.txt, and replace all ‘==’ with ‘>>’. Use the ‘Replace All’ command in the editor.

powershell -Command "(gc requirements.txt) -replace '==', '>>' | Out-File requirements.txt"

3 c:\pip install -r requirements.txt --upgrade