Python PasteScript 的粘贴器创建的替代品?
似乎 PasteScript 的 paster create
功能是唯一广泛使用的框架用于在 python 中构建/生成项目骨架。我想知道人们在 python 世界中是否有其他选择?
更新
我想评论一下我最初提出这个问题以来的经历。接受的答案仍然有效 - 有许多模板/骨架包可供使用。 然而,从给出的其他答案来看,我确实开始使用 mr.bob 并检查了< a href="https://github.com/audreyr/cookiecutter" rel="noreferrer">cookiecutter。两者都是通用(不受特定框架的约束)、易于使用并且相对当前和活跃项目 - 这是我正在寻找的标准的一部分,但在我原来的问题中没有详细说明。
It seems like PasteScript's paster create
functionality is just about the only widely used framework for building/generating a project skeleton within python. I'm wondering if there are any alternatives in the python world that folks use?
Update
I want to comment on my experience since originally asking this question. The accepted answer still stands - there are a number of templating/skeleton packages out there one could use.
However, from the other answers given, I did start to use mr.bob and have checked out cookiecutter. Both are generic (as in not bound to a particular framework), easy to use and relatively current and active projects - which were part of the criteria I was looking for but did not detail in my original question.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
还有我在搜索这些类型的工具时刚刚遇到的 Python Packager。它的用例似乎相当狭窄,但对于那些寻求提取 OSS 许可证文件帮助的人来说可能会很好。
There is also the Python Packager that I just ran across while searching for these types of tools. It appears to have a fairly narrow use case, but it might nice for those looking for help pulling OSS license files.
我相当偏爱 cookiecutter。它适用于 Linux、Mac OS X 和 Windows 上的 Python 2.7、3.3、3.4 和 PyPy。它有完整的文档、积极的维护、良好的测试并且非常易于使用。这是我的博客条目。它甚至有自己的 Stack Overflow 标签:https://stackoverflow.com/questions/tagged/cookiecutter
I'm rather partial to cookiecutter. It works for Python 2.7, 3.3, 3.4, and PyPy on Linux, Mac OS X, and Windows. It's fully documented, actively maintained, well tested, and really easy to use. Here is my blog entry on it. It even has its own Stack Overflow tag: https://stackoverflow.com/questions/tagged/cookiecutter
“骷髅”看起来很有前途。
"Skeleton" looks very promising.
http://pypi.python.org/pypi/skeleton/
由于我正在发布 mr.bob 0.1a6,它的大部分功能都与 PasteScript 一样完整。它是一个通用的目录骨架生成器,不需要 Python 知识来编写新的骨架。
文档:http://mrbob.readthedocs.org/en/latest/
As I'm in the process of releasing mr.bob 0.1a6, it is mostly feature complete as PasteScript. It is a general purpose directory skeleton generator that shouldn't require Python knowledge to write new skeletons.
Documentation: http://mrbob.readthedocs.org/en/latest/
这取决于你的框架。对于 Django 应用程序,您使用
django-admin.py startproject mysite
。对于在 Linux 上开发 GUI 应用程序,有 Ubuntu 的 Quickly,它也创建了一个框架项目。对于粘贴项目,您可以使用 Paster。不过,对于您正在做的事情来说,并没有真正的通用工具。这取决于框架,通常这些脚本带有特定的框架。就其价值而言,PyCharm(一个 IDE)包含一些项目模板,例如 Google App Engine 也是如此。
It depends on your framework. For Django applications, you use
django-admin.py startproject mysite
. For developing GUI applications on Linux, there's Ubuntu's Quickly, which also creates a skeleton project. For Paste projects, you use paster.There's not really a general purpose tool for what you're doing though. It depends on the framework, and usually, those scripts come with particular frameworks. And for what it's worth, PyCharm (an IDE) includes some project templates for things like Google App Engine too.