-
Notifications
You must be signed in to change notification settings - Fork 362
Translate B-embedding-git libgit2 #126
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Libgit2 is a dependency-free implementation of Git, with a focus on having a nice API for use within other programs. | ||
You can find it at http://libgit2.github.com[]. | ||
另外一种可以列入考虑的方式就是使用 Libgit2 。 | ||
Libgit2 是一个致力于提供一个更好的 API 去让其它程序使用的 Git 的非依赖性的工具。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Libgit2 是一个 Git 的非依赖性的工具,它致力于为其他程序使用 Git 提供更好的 API。
但是感觉还是不太通顺……
@IceNature 已修改,并提出 1 个疑问。 |
Another option at your disposal is to use Libgit2. | ||
Libgit2 is a dependency-free implementation of Git, with a focus on having a nice API for use within other programs. | ||
You can find it at http://libgit2.github.com[]. | ||
另外一种可以列入考虑的方式就是使用 Libgit2 。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
另外一种方式供你使用的是 Libgit2 。
感觉比较通顺,承接第一段
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这样句子不太通顺。联系本章开头的介绍,我决定
另外一种可以供你使用的是 Libgit2。
已完成 @Geno1024 |
---- | ||
|
||
|
||
==== Further Reading | ||
==== 拓展阅读 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
扩展阅读
你可以发现,代码看起来更加清晰了。 | ||
首先, Rugged 使用异常机制,它可以抛出类似于 `ConfigError` 或者 `ObjectError` 之类的东西来告知错误的情况。 | ||
其次,不需要明确的资源释放,因为 Ruby 是支持垃圾回收的。 | ||
我们来看一下一个稍微复杂一点的例子:从头开始制作一个提交。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
「来看一下一个」直接写成「来看一个」语义会更清晰一些吧
已完成 @Geno1024 |
Let's take a look at a slightly more complicated example: crafting a commit from scratch | ||
你可以发现,代码看起来更加清晰了。 | ||
首先, Rugged 使用异常机制,它可以抛出类似于 `ConfigError` 或者 `ObjectError` 之类的东西来告知错误的情况。 | ||
其次,不需要明确的资源释放,因为 Ruby 是支持垃圾回收的。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
“明确的”中的“的”字建议删除。
不需要明确的资源释放,揣测了下这句的意思,是不是说不需要显式声明资源释放?或者换种说法?
@Geno1024 请统一英文行数与中文行数并及时修正。 |
@tankxu @branchzero 已修改。 |
The official collection of bindings can be found by browsing the repositories at https://github.com/libgit2[]. | ||
The code we'll write will return the commit message from the commit eventually pointed to by HEAD (sort of like `git log -1`). | ||
Libgit2 有很多种语言的绑定。 | ||
在这篇文章中,我们展现了一个使用了几个更加完整的绑定包的小例子,这些库存在于许多种语言中,包括 C++, Go, Node.js, Erlang, 以及 JVM ,它们的成熟度各不相同。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
包括 C++, Go, Node.js, Erlang, 以及 JVM
=>
包括 C++、Go、Node.js、Erlang 以及 JVM
@Geno1024 刚才出去了一趟,没看完,实在抱歉。现在已经审核完毕,请查收:) |
@branchzero 已收到并全部修复~ |
Translate B-embedding-git libgit2
@Geno1024 @IceNature @fatjyc @tankxu @branchzero 已合并入主干。 |
No description provided.