在 requirements.txt 中指定大于或等于 Git 的标记
Specify greater than or equal to Git tag in requirements.txt
在我的 requirements.txt 中,我想指定我需要大于或等于 Python 依赖项的特定版本。如果我想从 PyPI 安装依赖项 Python 包,我可以这样做:
ExamplePackage>=0.2
但是如果我想指定 GitHub URL 来安装呢?我知道您可以指定一个确切的标签:
-e git://github.com/my-username/ExamplePackage.git@v0.2
但是我可以指定一个 >= 吗?
不幸的是,不可能。
查看 list of supported git specifications in the official doc,其中 none 允许 >=
虽然有人添加它似乎是有用的功能
在我的 requirements.txt 中,我想指定我需要大于或等于 Python 依赖项的特定版本。如果我想从 PyPI 安装依赖项 Python 包,我可以这样做:
ExamplePackage>=0.2
但是如果我想指定 GitHub URL 来安装呢?我知道您可以指定一个确切的标签:
-e git://github.com/my-username/ExamplePackage.git@v0.2
但是我可以指定一个 >= 吗?
不幸的是,不可能。
查看 list of supported git specifications in the official doc,其中 none 允许 >=
虽然有人添加它似乎是有用的功能