如何使用简单的安装后脚本扩展distutils?

如何使用简单的安装后脚本扩展distutils?,第1张

如何使用简单的安装后脚本扩展distutils?

我花了一天时间浏览distutils源码,以了解足够的知识来制作一堆自定义命令。它虽然不漂亮,但确实有效。

import distutils.corefrom distutils.command.install import install...class my_install(install):    def run(self):        install.run(self)        # Custom stuff here        # distutils.command.install actually has some nice helper methods        # and interfaces. I strongly suggest reading the docstrings....distutils.core.setup(..., cmdclass=dict(install=my_install), ...)


欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/zaji/5644487.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-12-16
下一篇 2022-12-16

发表评论

登录后才能评论

评论列表(0条)

保存