1. 09 Oct, 2012 1 commit
  2. 22 Sep, 2012 1 commit
  3. 27 Aug, 2012 1 commit
    • Make git_object_peel a bit smarter · d8057a5b
      This expands the types of peeling that `git_object_peel` knows
      how to do to include TAG -> BLOB peeling, and makes the errors
      slightly more consistent depending on the situation.  It also
      adds a new special behavior where peeling to ANY will peel until
      the object type changes (e.g. chases TAGs to a non-TAG).
      
      Using this expanded peeling, this replaces peeling code that was
      embedded in `git_tag_peel` and `git_reset`.
      Russell Belfer committed
  4. 19 Jun, 2012 1 commit
    • message: Expose git_message_prettify() · 743a4b3b
      git_commit() and git_tag() no longer prettify the
      message by default. This has to be taken care of
      by the caller.
      
      This has the nice side effect of putting the
      caller in position to actually choose to strip
      the comments or not.
      nulltoken committed
  5. 17 May, 2012 2 commits
  6. 07 May, 2012 1 commit
  7. 03 May, 2012 1 commit
  8. 26 Apr, 2012 1 commit
  9. 17 Apr, 2012 1 commit
  10. 10 Apr, 2012 1 commit
  11. 06 Mar, 2012 1 commit
    • error-handling: Repository · cb8a7961
      This also includes droping `git_buf_lasterror` because it makes no sense
      in the new system. Note that in most of the places were it has been
      dropped, the code needs cleanup. I.e. GIT_ENOMEM is going away, so
      instead it should return a generic `-1` and obviously not throw
      anything.
      Vicent Martí committed
  12. 22 Feb, 2012 1 commit
  13. 13 Feb, 2012 1 commit
  14. 08 Dec, 2011 1 commit
    • Use git_buf for path storage instead of stack-based buffers · 97769280
      This converts virtually all of the places that allocate GIT_PATH_MAX
      buffers on the stack for manipulating paths to use git_buf objects
      instead.  The patch is pretty careful not to touch the public API
      for libgit2, so there are a few places that still use GIT_PATH_MAX.
      
      This extends and changes some details of the git_buf implementation
      to add a couple of extra functions and to make error handling easier.
      
      This includes serious alterations to all the path.c functions, and
      several of the fileops.c ones, too.  Also, there are a number of new
      functions that parallel existing ones except that use a git_buf
      instead of a stack-based buffer (such as git_config_find_global_r
      that exists alongsize git_config_find_global).
      
      This also modifies the win32 version of p_realpath to allocate whatever
      buffer size is needed to accommodate the realpath instead of hardcoding
      a GIT_PATH_MAX limit, but that change needs to be tested still.
      Russell Belfer committed
  15. 26 Nov, 2011 2 commits
    • Rename all `_close` methods · 45e79e37
      There's no difference between `_free` and `_close` semantics: keep
      everything with the same name to avoid confusions.
      Vicent Marti committed
    • repository: Change ownership semantics · 9462c471
      The ownership semantics have been changed all over the library to be
      consistent. There are no more "borrowed" or duplicated references.
      
      Main changes:
      
      	- `git_repository_open2` and `3` have been dropped.
      
      	- Added setters and getters to hotswap all the repository owned
      	objects:
      
      		`git_repository_index`
      		`git_repository_set_index`
      		`git_repository_odb`
      		`git_repository_set_odb`
      		`git_repository_config`
      		`git_repository_set_config`
      		`git_repository_workdir`
      		`git_repository_set_workdir`
      
      	Now working directories/index files/ODBs and so on can be
      	hot-swapped after creating a repository and between operations.
      
      	- All these objects now have proper ownership semantics with
      	refcounting: they all require freeing after they are no longer
      	needed (the repository always keeps its internal reference).
      
      	- Repository open and initialization has been updated to keep in
      	mind the configuration files. Bare repositories are now always
      	detected, and a default config file is created on init.
      
      	- All the tests affected by these changes have been dropped from the
      	old test suite and ported to the new one.
      Vicent Marti committed
  16. 06 Nov, 2011 1 commit
  17. 29 Oct, 2011 1 commit
  18. 12 Oct, 2011 2 commits
  19. 19 Sep, 2011 1 commit
    • Tabify everything · 87d9869f
      There were quite a few places were spaces were being used instead of
      tabs. Try to catch them all. This should hopefully not break anything.
      Except for `git blame`. Oh well.
      Vicent Marti committed
  20. 18 Sep, 2011 1 commit
    • Cleanup legal data · bb742ede
      1. The license header is technically not valid if it doesn't have a
      copyright signature.
      
      2. The COPYING file has been updated with the different licenses used in
      the project.
      
      3. The full GPLv2 header in each file annoys me.
      Vicent Marti committed
  21. 25 Aug, 2011 1 commit
  22. 20 Jul, 2011 1 commit
  23. 11 Jul, 2011 1 commit
  24. 10 Jul, 2011 1 commit
  25. 09 Jul, 2011 3 commits
    • Remove unused methods · 06c43821
      The direct-writes commit left some (slow) internals methods that
      were no longer needed. These have been removed.
      
      Also, the Reflog code was using the old `git_signature__write`, so
      it has been rewritten to use a normal buffer and the new `writebuf`
      signature writer. It's now slightly simpler and faster.
      Vicent Marti committed
    • odb: Direct writes are back · afeecf4f
      DIRECT WRITES ARE BACK AND FASTER THAN EVER. The streaming writer to the
      ODB was an overkill for the smaller objects like Commit and Tags; most
      of the streaming logic was taking too long.
      
      This commit makes Commits, Tags and Trees to be built-up in memory, and
      then written to disk in 2 pushes (header + data), instead of streaming
      everything.
      
      This is *always* faster, even for big files (since the git_filebuf class
      still does streaming writes when the memory cache overflows). This is
      also a gazillion lines of code smaller, because we don't have to
      precompute the final size of the object before starting the stream (this
      was kind of defeating the point of streaming, anyway).
      
      Blobs are still written with full streaming instead of loading them in
      memory, since this is still the fastest way.
      
      A new `git_buf` class has been added. It's missing some features, but
      it'll get there.
      Vicent Marti committed
  26. 07 Jul, 2011 1 commit
  27. 05 Jul, 2011 1 commit
    • fileops: Cleanup · f79026b4
      Cleaned up the structure of the whole OS-abstraction layer.
      
      fileops.c now contains a set of utility methods for file management used
      by the library. These are abstractions on top of the original POSIX
      calls.
      
      There's a new file called `posix.c` that contains
      emulations/reimplementations of all the POSIX calls the library uses.
      These are prefixed with `p_`. There's a specific posix file for each
      platform (win32 and unix).
      
      All the path-related methods have been moved from `utils.c` to `path.c`
      and have their own prefix.
      Vicent Marti committed
  28. 01 Jul, 2011 1 commit
  29. 28 Jun, 2011 1 commit
    • Remove redundant methods from the API · d5afc039
      A bunch of redundant methods have been removed from the external API.
      
      - All the reference/tag creation methods with `_f` are gone. The force
      flag is now passed as an argument to the normal create methods.
      
      - All the different commit creation methods are gone; commit creation
      now always requires a `git_commit` pointer for parents and a `git_tree`
      pointer for tree, to ensure that corrupted commits cannot be generated.
      
      - All the different tag creation methods are gone; tag creation now
      always requires a `git_object` pointer to ensure that tags are not
      created to inexisting objects.
      Vicent Marti committed
  30. 23 Jun, 2011 1 commit
  31. 16 Jun, 2011 1 commit
  32. 07 Jun, 2011 1 commit
  33. 31 May, 2011 3 commits