include


Log

Author Commit Date CI Message
Vicent Marti 7064938b 2011-03-14T23:55:32 libgit2 version 0.10.0, "very disco" A version *so* awesome that needs 2 version bumps AND a codename. Major features: - New internal garbage collection (harder) - Pack backend rewritten from scratch (better) - Revision walker rewritten from scratch (faster) - New object interdependency system (stronger) - Unique OID shortener - Reference listing In honor of one heck of a music album, released ten years ago, yesterday.
Vicent Marti 6b2a1941 2011-03-12T23:09:16 Fix the retarded object interdependency system It's no longer retarded. All object interdependencies are stored as OIDs instead of actual objects. This should be hundreds of times faster, specially on big repositories. Heck, who knows, maye it doesn't even segfault -- wouldn't that be awesome? What has changed on the API? `git_commit_parent`, `git_commit_tree`, `git_tag_target` now return their values through a pointer-to-pointer, and have an error code. `git_commit_set_tree` and `git_tag_set_target` now return an error code and may fail. `git_repository_free__no_gc` has been deprecated because it's stupid. Since there are no longer any interdependencies between objects, we don't need internal reference counting, and GC never fails or double-free's pointers. `git_object_close` now does a very sane thing: marks an object as unused. Closed objects will be eventually free'd from the object cache based on LRU. Please use `git_object_close` from the garbage collector `destroy` method on your bindings. It's 100% safe. `git_repository_gc` is a new method that forces a garbage collector pass through the repo, to free as many LRU objects as possible. This is useful if we are running out of memory.
Vicent Marti 00571828 2011-03-12T16:04:46 Add new method `git_reference_listall` Lists all the references in a repository. Listing may be filtered by reference type. This should applease Lord Clem.
Vicent Marti 71db842f 2011-03-08T14:57:03 Rewrite the Revision Walker The new revision walker uses an internal Commit object storage system, custom memory allocator and much improved topological and time sorting algorithms. It's about 20x times faster than the previous implementation when browsing big repositories. The following external API calls have changed: `git_revwalk_next` returns an OID instead of a full commit object. The initial call to `git_revwalk_next` is no longer blocking when iterating through a repo with a time-sorting mode. Iterating with Topological or inverted modes still makes the initial call blocking to preprocess the commit list, but this block should be mostly unnoticeable on most repositories (topological preprocessing times at 0.3s on the git.git repo). `git_revwalk_push` and `git_revwalk_hide` now take an OID instead of a full commit object.
Vicent Marti 26022f07 2011-03-05T23:54:49 Add `git_oid_shorten` (unique OID minimzer) Set of methods to find the minimal-length to uniquely identify every OID in a list. Useful for GUI applications, commit logs and so on. Includes stress test. Signed-off-by: Vicent Marti <tanoku@gmail.com>
Vicent Marti 545a6915 2011-03-05T13:45:05 Change interface for Tree Index attr (always unsigned) Signed-off-by: Vicent Marti <tanoku@gmail.com>
Sakari Jokinen 9de27ad0 2011-02-25T19:05:29 Check for valid range of attributes for tree entry
Vicent Marti 3490188b 2011-03-05T13:29:50 Change the return type of `git_blob_rawcontent` Should return `void *` for raw bytes. Signed-off-by: Vicent Marti <tanoku@gmail.com>
Vicent Marti b64e11d1 2011-03-03T20:23:04 Bump the version number to 0.8.0 Yes, these are some seriously massive changes to the external API. We are breaking stuff. Signed-off-by: Vicent Marti <tanoku@gmail.com>
Vicent Marti 71d33382 2011-03-03T20:20:45 Move the external includes folder from `src` to `include` Signed-off-by: Vicent Marti <tanoku@gmail.com>
Andreas Ericsson 1b9e92c7 2008-11-18T01:02:27 s/git_revp/git_revpool/ git_revp is something I personally can't stop pronouncing "rev pointer". I'm sure others would suffer the same problem. Also, rename the git_revp_ sub-api "gitrp_". This is the first of many such renames, primarily done to prevent extreme inflation in the "git_" namespace, which we'd like to reserve for a higher-level API. While we're at it, we remove the noise-char "c" from a lot of functions. Since revision walking is all about commits, the common case should be that we're dealing with commits. Exceptions can get a more mnemonic description as needed. Signed-off-by: Andreas Ericsson <ae@op5.se> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Andreas Ericsson d4043ee9 2008-11-18T01:18:52 Move public headers to src/git It's arguably smoother to keep them close to the source, as that's where one's working when modifying them. More importantly, though, is the ability to use private headers in the src/ dir that simply include "git/$samename.h" to get to the public API at the same time. Signed-off-by: Andreas Ericsson <ae@op5.se> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Andreas Ericsson dff79e27 2008-11-18T00:59:36 Rename "git_sobj" "git_obj" The 's' never really made sense, since it's not a "small" object at all, but rather a plain object. As such, it should have a "plain" object name. Signed-off-by: Andreas Ericsson <ae@op5.se> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Andreas Ericsson 257bd746 2008-11-18T00:58:02 Use same-directory include for public headers It doesn't make sense to use "git/somefile.h" in the public git headers, as it's quite likely that projects using them will have a git directory themselves. This alters it, making the public headers look for headers in the same directory they themselves are in. Signed-off-by: Andreas Ericsson <ae@op5.se> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce 8b6f008e 2008-11-03T18:53:09 Add a zlib support shell Some versions of zlib don't have a deflateBound defined, so we define it ourselves after including zlib.h. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce 1699efc4 2008-11-03T18:39:37 Implement some of the basic git_odb open and close API Far from being complete, but its a good start. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce 2dbdb824 2008-11-03T18:38:57 Add git_fsize to the os file API This permits us to get the size of an opened file. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce 3e9e6909 2008-11-03T17:14:25 Redefine git_fread, git_fwrite to transfer the whole unit We never want to accept a short read or a short write when transferring data to or from a local file. Either the entire read (or write) completes or the operation failed and we will not recover gracefully from it. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce b7c891c6 2008-11-03T17:31:16 Add git_oid_cpy, git_oid_cmp as inline functions These are easily built off the standard C library functions memcpy and memcmp. By marking these inline we stand a good chance of the C compiler replacing the entire thing with tight machine code, because many compilers will actually inline a memcmp or memcpy when the 3rd argument (the size) is a constant value. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce fbbfdf9f 2008-11-03T16:29:56 Move GIT_NORETURN into test_lib.h only We should never have a noreturn style function in the library itself, as such a function would prevent the calling application from handling error conditions the way it wants. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce 3b8ab0b9 2008-11-03T16:29:03 Fix GIT_EXTERN to actually mark the prototype as extern Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce 8722a77e 2008-11-03T17:52:59 Correct indentation in git/odb.h Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce 15bffce9 2008-11-01T18:14:22 Create a basic test suite for the library and test oid functions This is a horribly simple test suite that makes it fairly easy to put together some basic function level unit tests on the library. Its patterned somewhat after the test suite in git.git, but also after the "Check" test library. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce 16a67770 2008-11-01T16:53:06 Create a micro abstraction around the POSIX file APIs This way we can start to write IO code to read and write files in the Git object database, but provide a hook to inject native Win32 APIs instead so libgit2 can be ported to run natively on that platform. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce 50298f44 2008-11-01T15:55:01 Switch the license from BSD to GPL+libgcc exception Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce d1ea30c3 2008-11-01T15:42:23 Move include files to include/git/, drop git_ prefix from file names Signed-off-by: Shawn O. Pearce <spearce@spearce.org>