如何管理同一个Python包的不同发行包?

发布于 2024-10-03 10:29:25 字数 141 浏览 0 评论 0原文

有没有办法(使用 distribute 或其他包)来管理不同的发行版(意味着不同的 setup.py 文件)同一个 Python 包?

Is there a way (with distribute or another package) to manage different distributions (meaning different setup.py files) of the same Python package?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

你是暖光i 2024-10-10 10:29:25

您可能会查看buildout。使用 buildout,您可以为一个包拥有一个 setup.py,并拥有多个 buildout 配置文件,这些文件指定与您想要在同一发行版中拥有的其他包(包括其版本依赖项)一起构建该包的不同方式。

我认为使用 pip freeze、pip bundle 您也可以实现类似的功能,但据我所知,仅适用于软件包的版本(例如,您无法安装和设置 LDAP 服务器,但您可以在构建中做到这一点)。

You might have a look to buildout. With buildout you can have a single setup.py for a package and have multiple buildout configuration files that specify different ways of building that package with the other packages you want to have in the same distribution (including its version dependencies).

I think with pip freeze, pip bundle you can also achieve something similar but AFAIK only for versions of packages (you can't install and setup an LDAP server for example, but you can do it that in buildout).

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文