使用pipreqs,这个工具的好处是可以通过对项目目录的扫描,发现使用了哪些库,生成依赖清单。
1. pip install pipreqs
2. 在项目的根目录下使用 pipreqs ./ 自动导出requirements.txt 文件
3. pip[python -m pip] install -r requirements.txt -i https://pypi.doubanio.com/simple/ 安装依赖文件里的依赖并指定源为豆瓣
使用pipreqs,这个工具的好处是可以通过对项目目录的扫描,发现使用了哪些库,生成依赖清单。
1. pip install pipreqs
2. 在项目的根目录下使用 pipreqs ./ 自动导出requirements.txt 文件
3. pip[python -m pip] install -r requirements.txt -i https://pypi.doubanio.com/simple/ 安装依赖文件里的依赖并指定源为豆瓣
本文标题:python requirements.txt
本文链接:https://www.haomeiwen.com/subject/gsewwctx.html
网友评论