你如何组织 Python 模块? [英] How do you organize Python modules?
本文介绍了你如何组织 Python 模块?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
说到组织python模块,我的Mac OS X系统一团糟.我的硬盘上到处都是包,但没有特定的系统来组织它们.
When it comes to organizing python modules, my Mac OS X system is a mess. I've packages lying around everywhere on my hdd and no particular system to organize them.
你如何让一切都易于管理?
How do you keep everything manageable?
推荐答案
我的建议:
- 阅读安装 Python 模块.
- 阅读分发 Python 模块.
- 从 setuptools 开始使用 easy_install.阅读 setuptools 的文档.
- 始终使用 virtualenv.我的站点包目录包含setuptools 和 virtualenv 仅.
- 查看 Ian Bicking 的新项目 pyinstall.
- 关注 Ian Bicking 正在进行的所有工作.它总是美好的.
- 创建自己的软件包时,请使用 distutils/setuptools.考虑使用
paster create
(参见 http://pythonpaste.org)来创建你的初始目录布局.
- Read Installing Python Modules.
- Read Distributing Python Modules.
- Start using easy_install from setuptools. Read the documentation for setuptools.
- Always use virtualenv. My site-packages directory contains setuptools and virtualenv only.
- Check out Ian Bicking's new project pyinstall.
- Follow everything Ian Bicking is working on. It is always goodness.
- When creating your own packages, use distutils/setuptools. Consider using
paster create
(see http://pythonpaste.org) to create your initial directory layout.
这篇关于你如何组织 Python 模块?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文