| Age | Commit message (Collapse) | Author |
|
This change introduces the file deprecated.go, which contains any
constants, functions, and types that are slated to be deprecated in the
next major release.
These symbols are deprecated because they refer to old spellings in
pre-1.0 libgit2. This also makes the build be done with the
`-DDEPRECATE_HARD` flag to avoid regressions.
This, together with
[gorelease](https://godoc.org/golang.org/x/exp/cmd/gorelease)[1] should
make releases safer going forward.
1: More information about how that works at
https://go.googlesource.com/exp/+/refs/heads/master/apidiff/README.md
|
|
|
|
Signed-off-by: Steffen Prohaska <[email protected]>
|
|
We do want to be able to accept generic objects in functions. Add this interface
so we can accept that instead of specific object types.
|
|
|
|
Fix memleaks in Tree.EntryBy(Name/Path/Index), fixes #313
|
|
As per the docs, these entries belong to the tree and don’t need to be
freed by the caller:
*
https://libgit2.github.com/libgit2/#HEAD/group/tree/git_tree_entry_bynam
e
|
|
|
|
TreeBuilder methods.
|
|
An Object should be about representing a libgit2 object rather than
showing which methods it should support.
Change any return of Object to *Object and provide methods to convert
between this and the particular type.
|
|
Add support for 'git_tree_entry_byid'.
|
|
|
|
|
|
|
|
Fix calls to C.git_treebuilder_create and C.git_treebuilder_write.
|
|
|
|
Fixes #121
|
|
Remove missing constants.
|
|
It does not like breaking aliasing rules, so let's keep a casted pointer
for when libgit2 wants that.
|
|
API cleanup
|
|
|
|
|
|
The library stores error information in thread-local storage, which
means we need to make sure that the Go runtime doesn't switch OS
threads between the time we call a function and th time we attempt to
retrieve the error information.
|
|
This allows us to restrict which constants the compiler will allow
through, and makes the sorting in the documentation better.
|
|
The more powerful version of EntryByName.
|
|
This field was missing, so let's add it, and let's add the const
definitions for the modes while we're here.
|
|
|
|
|
|
|
|
Name it like The Library and the rest of the bindings.
|
|
Provide a manual way of freeing objects, but set finalizers for them
in case the user does not want to worry about memory management, which
would be useful for commits or trees, which sare typically small.
When the objects are freed manually, the finalizer is unset to avoid
double-freeing, mimicking what the go runtime does.
|
|
|