分发 Python 应用程序
快速问题...一旦我使用 wx gui 等构建了 .py 应用程序...我可以使用 pyinstaller 或 cx_freeze 编译它,并将二进制文件发送到我的服务器,对吗?
这是分发脚本的好方法吗?我对应用程序开发周期相当陌生......我有一些我想公开的Python脚本,因为它们让我的生活更轻松......
如果你要与社区的其他人分享一些代码,请为人们提供.py 代码,并且还想分发二进制文件,您会使用 pyinstaller 和 cx_freeze 编译 .py,还是会使用其他方法?
目前的开发环境是 Mac OSX 和 debian domU...
谢谢!
Quick question... Once I build a .py app, with wx gui, etc... I can compile it with pyinstaller or cx_freeze, and send the binaries to my servers, correct?
Is this a good way to distribute a script? I am fairly new to app development cycle... I have a few python script which I would like to make public, because they make my life easier...
If you were to share some code with the rest of community, provide people the .py code, and wanted to distribute binaries as well, would you compile .py with pyinstaller and cx_freeze, or would you use some other method?
Dev environment currently is Mac OSX, and a debian domU....
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
最佳解决方案取决于您将其发布给谁,以及您将根据什么许可证发布它。
如果您不担心泄露您所分发的应用程序的代码,那么像 github 或 bitbucket 这样的服务就是您的最佳选择。向社区贡献代码的最佳方式(如果您将其开源)是通过版本控制,因为它允许人们贡献代码并从中学习。
但是,根据您的受众,您可能需要更“用户友好”的东西。在这种情况下,cx_freeze和pyinstaller是完全可以接受的解决方案。
如果您要分发软件包,您可能需要查看setuptools< /a>
The best solution depends on who you're releasing it to, and what license you're releasing it under.
If you're not concerned about revealing the code of the apps you're distributing, then a service like github or bitbucket is the way to go. The best way to contribute your code to a community (if you're releasing it open source) is through version control because it allows people to contribute and learn from it.
But, depending on your audience, you might need something more "user-friendly". In which case, cx_freeze and pyinstaller are perfectly acceptable solutions.
If you're distributing a package, you may want to look into setuptools
另请参阅 http://wiki.python.org/moin/DistributionUtilities 和 如何分发 Python 程序?
要在线共享开源项目,GitHub 是流行的选择。
See also http://wiki.python.org/moin/DistributionUtilities and How can I distribute Python programs?
To share open source projects online, GitHub is the popular choice.