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: README.md
+8-7
Original file line number
Diff line number
Diff line change
@@ -10,20 +10,21 @@ Due to the fact that Go 1.11 module versions have semantic meaning and don't nec
10
10
11
11
| libgit2 | git2go |
12
12
|---------|---------------|
13
-
| main | (will be v32) |
13
+
| main | (will be v33) |
14
+
| 1.2 | v32 |
14
15
| 1.1 | v31 |
15
16
| 1.0 | v30 |
16
17
| 0.99 | v29 |
17
18
| 0.28 | v28 |
18
19
| 0.27 | v27 |
19
20
20
-
You can import them in your project with the version's major number as a suffix. For example, if you have libgit2 v1.1 installed, you'd import git2go v31 with:
21
+
You can import them in your project with the version's major number as a suffix. For example, if you have libgit2 v1.2 installed, you'd import git2go v32 with:
21
22
22
23
```sh
23
-
go get github.com/libgit2/git2go/v31
24
+
go get github.com/libgit2/git2go/v32
24
25
```
25
26
```go
26
-
import"github.com/libgit2/git2go/v31"
27
+
import"github.com/libgit2/git2go/v32"
27
28
```
28
29
29
30
which will ensure there are no sudden changes to the API.
@@ -44,10 +45,10 @@ This project wraps the functionality provided by libgit2. If you're using a vers
44
45
45
46
### Versioned branch, dynamic linking
46
47
47
-
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 v1.1
48
+
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 v1.2
48
49
49
50
```go
50
-
import"github.com/libgit2/git2go/v31"
51
+
import"github.com/libgit2/git2go/v32"
51
52
```
52
53
53
54
### Versioned branch, static linking
@@ -77,7 +78,7 @@ In order to let Go pass the correct flags to `pkg-config`, `-tags static` needs
77
78
78
79
One thing to take into account is that since Go expects the `pkg-config` file to be within the same directory where `make install-static` was called, so the `go.mod` file may need to have a [`replace` directive](https://github.com/golang/go/wiki/Modules#when-should-i-use-the-replace-directive) so that the correct setup is achieved. So if `git2go` is checked out at `$GOPATH/src/github.com/libgit2/git2go` and your project at `$GOPATH/src/github.com/my/project`, the `go.mod` file of `github.com/my/project` might need to have a line like
0 commit comments