You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: book/B-embedding-git/sections/go-git.asc
+9-9Lines changed: 9 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,11 +2,12 @@
2
2
3
3
(((go-git)))((("Go")))
4
4
In case you want to integrate Git into a service written in Golang, there also is a pure Go library implementation.
5
-
In contrast to using a Libgit2 bindings, this implementation does not have any native dependencies, not prone to memory management errors and is transparent for standard Golang performance analysis tooling like CPU, Memory profilers, race detector, etc.
5
+
This implementation does not have any native dependencies and thus is not prone to manual memory managemen errors.
6
+
It is also transparent for the standard Golang performance analysis tooling like CPU, Memory profilers, race detector, etc.
6
7
7
-
go-git is focused on extensibility, compatibility and supports most of the plumbing APIs, which is documented https://github.com/src-d/go-git/blob/master/COMPATIBILITY.md[]
8
+
go-git is focused on extensibility, compatibility and supports most of the plumbing APIs, which is documented at https://github.com/src-d/go-git/blob/master/COMPATIBILITY.md[].
As soon as you have a `Repository` instance, you can access information and perform mutations on it:
22
23
23
24
24
25
[source, go]
@@ -41,7 +42,8 @@ for _, c := range history {
41
42
42
43
==== Advanced Functionality
43
44
44
-
go-git has few notable advanced features, one of which is a pluggable storage system, similar to Libgit2 backends, with a default implementation of in-memory storage.
45
+
go-git has few notable advanced features, one of which is a pluggable storage system, which is similar to Libgit2 backends.
46
+
The default implementation is in-memory storage, which is very fast.
That way all operations over the repository become blazingly fast as they never hit the disk.
54
-
55
-
Other storage implementations include ability to store references, objects and configuration in a database i.e https://github.com/src-d/go-git/tree/master/_examples/storage[] an Aerospike.
55
+
Pluggable storage provides many interesting options. For instance, https://github.com/src-d/go-git/tree/master/_examples/storage[] allows you to store references, objects, and configuration in an Aerospike database.
56
56
57
57
Another feature is a flexible filesystem abstraction.
58
58
Using https://godoc.org/github.com/src-d/go-billy#Filesystem[] it is easy to store all the files in different way i.e by packing all of them to a single archive on disk or by keeping them all in-memory.
59
59
60
-
Another advanced use-case includes a fine-tunable HTTP clienthttps://github.com/src-d/go-git/blob/master/_examples/custom_http/main.go[]
60
+
Another advanced use-case includes a fine-tunable HTTP client, such as the one found at https://github.com/src-d/go-git/blob/master/_examples/custom_http/main.go[].
0 commit comments