Skip to content

Commit 2b66c0f

Browse files
authored
Update README.md
Clarifying the versions since we're using Go 1.11 module version rules now.
1 parent a32375a commit 2b66c0f

File tree

1 file changed

+23
-6
lines changed

1 file changed

+23
-6
lines changed

README.md

Lines changed: 23 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,30 @@ git2go
44

55
Go bindings for [libgit2](http://libgit2.github.com/).
66

7-
### Which branch to use
7+
### Which Go version to use
88

9-
The numbered branches work against the version of libgit2 as specified by their number. You can import them in your project via gopkg.in, e.g. if you have libgit2 v0.25 installed you'd import with
9+
Due to the fact that Go 1.11 module versions have semantic meaning and don't necessarily align with libgit2's release schedule, please consult the following table for a mapping between libgit2 and git2go module versions:
1010

11-
import "gopkg.in/libgit2/git2go.v25"
11+
| libgit2 | git2go |
12+
|---------|---------------|
13+
| master | (will be v30) |
14+
| 0.99 | v29 |
15+
| 0.28 | v28 |
16+
| 0.27 | v27 |
17+
18+
You can import them in your project via `go get` or a regular `import` with the version number as a suffix. For example, if you have libgit2 v0.99 installed, you'd import with
19+
20+
```go
21+
import "github.com/libgit2/git2go/v29"
22+
```
1223

1324
which will ensure there are no sudden changes to the API.
1425

15-
The `master` branch follows the tip of libgit2 itself (with some lag) and as such has no guarantees on its own API nor does it have expectations the stability of libgit2's. Thus this only supports statically linking against libgit2.
26+
The `master` branch follows the tip of libgit2 itself (with some lag) and as such has no guarantees on the stability of libgit2's API. Thus this only supports statically linking against libgit2.
27+
28+
### Which branch to send Pull requests to
29+
30+
If there's something version-specific that you'd want to contribute to, you can send them to the `release-${MAJOR}-${MINOR}` branches, which follow libgit2's releases.
1631

1732
Installing
1833
----------
@@ -24,9 +39,11 @@ This project wraps the functionality provided by libgit2. If you're using a vers
2439

2540
### Versioned branch, dynamic linking
2641

27-
When linking dynamically against a released version of libgit2, install it via your system's package manager. CGo will take care of finding its pkg-config file and set up the linking. Import via gopkg.in, e.g. to work against libgit2 v0.25
42+
When linking dynamically against a released version of libgit2, install it via your system's package manager. CGo will take care of finding its pkg-config file and set up the linking. Import via Go modules, e.g. to work against libgit2 v0.99
2843

29-
import "gopkg.in/libgit2/git2go.v25"
44+
```go
45+
import "github.com/libgit2/git2go/v29"
46+
```
3047

3148
### Master branch, or static linking
3249

0 commit comments

Comments
 (0)