summaryrefslogtreecommitdiff
path: root/blob.go
AgeCommit message (Collapse)Author
2021-09-05Make all non-user-creatable structures non-comparable (#802)lhchavez
This change makes all non-user-creatable structures non-comparable. This makes it easier to add changes later that don't introduce breaking changes from the go compatibility guarantees perspective. This, of course, implies that this change _is_ a breaking change, but since these structures are not intended to be created by users (or de-referenced), it should be okay.
2020-12-05Mark some symbols to be deprecated #minor (#698)lhchavez
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
2020-07-30Add support for git_blob_is_binary (#625)Yuichi Watanabe
This adds IsBinary() func to Blob struct, which simply returns the result of git_blob_is_binary function. Refs: https://libgit2.org/libgit2/#HEAD/group/blob/git_blob_is_binary Issue: Add support for git_blob_is_binary #426 Fixes: #426
2017-07-11fixed typosreujab
2017-07-08Add Objecer interfaceCarlos Martín Nieto
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.
2017-07-08First round of mass keep-alive additionsCarlos Martín Nieto
2016-08-27Merge remote-tracking branch 'upstream/master' into nextCarlos Martín Nieto
2016-08-27Work around Go 1.6's CGo pointer checkCarlos Martín Nieto
It depends heavily on the expression at the call site an whether it can figure out whether we're using a slice or not, so provid an incantation that does this.
2016-04-23Update to 1dc4491Carlos Martín Nieto
2016-02-15Merge remote-tracking branch 'upstream/master' into nextCarlos Martín Nieto
2016-01-04Don't drop CreateBlobFromChunks hintPath argumentMichael Gehring
2015-08-04Move from an Object interface to a typeCarlos Martín Nieto
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.
2015-05-22blob: use HandleList for C function callbacks.Patrick Steinhardt
2014-12-11Remove useless includesCarlos Martín Nieto
2014-08-25Handle empty slices in CreateBlobFromBuffer()Carlos Martín Nieto
Go won't let us access the zeroth alement of an empty slice, so we need to figure out if the length is zero and take special action. This fixes #106.
2014-04-01Adjust to Go tip changesCarlos Martín Nieto
It does not like breaking aliasing rules, so let's keep a casted pointer for when libgit2 wants that.
2014-03-16fix chunk create logicJesse Ezell
2014-03-07add blob chunk creation, creation of tree builders for specific trees, minor ↵Jesse Ezell
API cleanup
2013-11-14Don't repeat the pkg-config lineCarlos Martín Nieto
This is only needed once per package. Having it on every file makes the build system ask about it n times, which is silly.
2013-04-18Ok, now with shared base objectVicent Marti
2013-04-16Take 2 on polymorphismVicent Marti
2013-03-06Add a couple of missing methods around BlobCarlos Martín Nieto
2013-03-06Free Git objects via finalizers or manuallyCarlos Martín Nieto
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.
2013-03-05Initial commitVicent Marti