简体   繁体   English

Git瓷器通过pygit2命令吗?

[英]Git porcelain commands via pygit2?

Pygit2 is a set of Python bindings to the libgit2 shared library, which implements the Git core methods. Pygit2是与libgit2共享库的一组Python绑定,该库实现了Git核心方法。 Unfortunately, it only seems to provide an API towards plumbing commands. 不幸的是,它似乎仅提供了用于管道命令的API。

Is there any python library built on the top of pygit2 which provides an implementation of the most common git porcelain commands? 是否在pygit2顶部构建了任何python库,该库提供了最常用的git ceramic命令的实现?

The plumbing commands are those which are only expected to interact with a user and as such their output is subject to change at any time and have a granularity which as a rule is not particularly useful for a computer programme. 管道命令是仅预期与用户交互的命令,因此它们的输出随时可能变化,并且具有通常对于计算机程序不是特别有用的粒度。

If you're not interested in the data structures from libgit2, but rather want to run pluming commands for scripting, you might want to take a look at GitPython which wraps git's own commands behind a python API. 如果您对libgit2的数据结构不感兴趣,而想运行用于编写脚本的羽化命令,则可能需要看看GitPython ,它将git自己的命令包装在python API之后。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM