summaryrefslogtreecommitdiff
path: root/include/git2
Commit message (Collapse)AuthorAgeFilesLines
...
* | filemode: introduce enum to ease use of attributesnulltoken2012-08-211-0/+10
|/
* treebuilder: enhance attributes handling on insertionnulltoken2012-08-191-1/+7
|
* Merge pull request #778 from ben/cloneVicent Martí2012-08-193-3/+131
|\ | | | | Clone
| * Add documentation for clone methods.Ben Straub2012-07-311-2/+3
| |
| * Add checkout.h to git2.h.Ben Straub2012-07-312-4/+4
| | | | | | Also correcting some documentation strings.
| * Enable stats on git_index_read_tree.Ben Straub2012-07-301-14/+2
| | | | | | | | | | Replace with the contents of git_index_read_tree_with_stats() and improve documentation comments.
| * Checkout: use git_index_read_tree_with_stats.Ben Straub2012-07-301-0/+15
| | | | | | | | | | New variant of git_index_read_tree that fills in the 'total' field of a git_indexer_stats struct as it's walking the tree.
| * Checkout: add head- and ref-centric checkouts.Ben Straub2012-07-271-9/+14
| | | | | | | | | | | | | | | | | | Renamed git_checkout_index to what it really was, and removed duplicate code from clone.c. Added git_checkout_ref, which updates HEAD and hands off to git_checkout_head. Added tests for the options the caller can pass to git_checkout_*.
| * Merge remote-tracking branch 'upstream/development' into test-mergeBen Straub2012-07-278-37/+174
| |\
| * | Checkout: implementation of most optionsBen Straub2012-07-261-1/+2
| | |
| * | Restructure for better checkout optionsBen Straub2012-07-262-21/+26
| | | | | | | | | | | | | | | | | | * Removed the #define for defaults * Promoted progress structure to top-level API call argument
| * | checkout: introduce git_checkout_optsBen Straub2012-07-261-3/+33
| | | | | | | | | | | | | | | Refactor checkout into several more-sensible entry points, which consolidates common options into a single structure that may be passed around.
| * | Merge branch 'development' into cloneBen Straub2012-07-1717-79/+215
| |\ \
| * | | Fix documentation comment to match actual params.Ben Straub2012-07-131-4/+1
| | | |
| * | | Clone: new home for git_checkout_force.Ben Straub2012-06-211-0/+38
| | | |
| * | | Add progress reporting to clone.Ben Straub2012-06-211-3/+6
| | | |
| * | | Add git_clone and git_clone_bare.Ben Straub2012-06-211-0/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | So far they only create a repo, setup the "origin" remote, and fetch. The API probably needs work as well; there's no way to get progress information at this point. Also uncovered a shortcoming; git_remote_download doesn't fetch over local transport.
* | | | refs: fix missing parameter documentationnulltoken2012-08-151-0/+2
| | | |
* | | | notes: slight documentation enhancementsnulltoken2012-08-151-12/+14
| | | |
* | | | Merge pull request #873 from carlosmn/tree-walkCarlos Martín Nieto2012-08-141-2/+3
|\ \ \ \ | | | | | | | | | | git_tree_walk callback return value semantic does not match documentation
| * | | | tree: allow the user to skip an entry or cancel the walkCarlos Martín Nieto2012-08-131-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Returning a negative cancels the walk, and returning a positive one causes us to skip an entry, which was previously done by a negative value. This allows us to stay consistent with the rest of the functions that take a callback and keeps the skipping functionality.
* | | | | Merge pull request #875 from arrbee/fix-message-prettify-length-checkRussell Belfer2012-08-141-3/+5
|\ \ \ \ \ | | | | | | | | | | | | Fix message prettify length check
| * | | | | Make git_message_prettify return bytes writtenRussell Belfer2012-08-141-3/+5
| |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If you want to be absolutely safe with git_message_prettify, you can now pass a NULL pointer for the buffer and get back the number of bytes that would be copied into the buffer. This means that an error is a non-negative return code and a success will be greater than zero from this function.
* | | | | Merge pull request #871 from joshtriplett/fix-note_foreach-docsVicent Martí2012-08-131-1/+1
|\ \ \ \ \ | | | | | | | | | | | | git_note_foreach: Fix documentation for notes_ref parameter
| * | | | | git_note_foreach: Fix documentation for notes_ref parameterJosh Triplett2012-08-121-1/+1
| |/ / / /
* | | | | Merge pull request #870 from joshtriplett/fix-note_create-docsVicent Martí2012-08-131-2/+2
|\ \ \ \ \ | | | | | | | | | | | | git_note_oid: Fix the documentation to reference parameters using the correct names
| * | | | | git_note_oid: Fix the documentation to reference parameters using the ↵Josh Triplett2012-08-121-2/+2
| |/ / / / | | | | | | | | | | | | | | | correct names
* | | | | Merge pull request #872 from joshtriplett/fix-note_remove-docsVicent Martí2012-08-131-1/+1
|\ \ \ \ \ | | | | | | | | | | | | git_note_create: Copyediting on documentation for the oid parameter
| * | | | | git_note_remove: Copyediting on documentation for the oid parameterJosh Triplett2012-08-121-1/+1
| |/ / / /
* | | | | Fix incorrect array size in example for git_config_get_mappedJosh Triplett2012-08-121-1/+1
|/ / / / | | | | | | | | | | | | | | | | | | | | In the documentation for git_config_get_mapped, the sample mapping array uses [3] but has 4 entries. Fix by dropping the size entirely and letting the compiler figure it out.
* | | | Export git_attr_valueJosh Triplett2012-08-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 0c9eacf3d2c83256736a5bb2a240e73afd13d55f introduced the function git_attr_value and switched the GIT_ATTR_* macros to use it, but attempting to use that function leads to a linker error (undefined reference to `git_attr_value'). Export git_attr_value so programs can actually call it.
* | | | Merge remote-tracking branch 'arrbee/tree-walk-fixes' into developmentVicent Marti2012-08-0611-29/+67
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/notes.c src/transports/git.c src/transports/http.c src/transports/local.c tests-clar/odb/foreach.c
| * | | | Update iterators for consistency across libraryRussell Belfer2012-08-0310-29/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This updates all the `foreach()` type functions across the library that take callbacks from the user to have a consistent behavior. The rules are: * A callback terminates the loop by returning any non-zero value * Once the callback returns non-zero, it will not be called again (i.e. the loop stops all iteration regardless of state) * If the callback returns non-zero, the parent fn returns GIT_EUSER * Although the parent returns GIT_EUSER, no error will be set in the library and `giterr_last()` will return NULL if called. This commit makes those changes across the library and adds tests for most of the iteration APIs to make sure that they follow the above rules.
| * | | | Fix git_tree_walk to return user errorRussell Belfer2012-07-261-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This makes sure that an error code returned by the callback function of `git_tree_walk` will stop the iteration and get propagated back to the caller verbatim. Also, this adds a minor helper function `git_tree_entry_byoid` that searches a `git_tree` for an entry with the given OID. This isn't a fast function, but it's easier than writing the loop yourself as an external user of the library.
* | | | | Merge remote-tracking branch 'nulltoken/topic/amd64-compat' into developmentVicent Marti2012-08-0210-12/+12
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/netops.c src/netops.h src/oid.c
| * | | | | portability: Improve x86/amd64 compatibilitynulltoken2012-07-2410-12/+12
| | | | | |
* | | | | | Merge pull request #850 from libgit2/attr-exportVicent Martí2012-08-011-9/+25
|\ \ \ \ \ \ | | | | | | | | | | | | | | attr: Do not export variables externally
| * | | | | | attr: Do not export variables externallyattr-exportVicent Marti2012-08-021-9/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes #824 Exporting variables in a dynamic library is a PITA. Let's keep these values internally and wrap them through a helper method. This doesn't break the external API. @arrbee, aren't you glad I turned the `GIT_ATTR_` macros into function macros? :sparkles:
* | | | | | | Merge pull request #848 from carlosmn/pending-messageVicent Martí2012-08-011-0/+22
|\ \ \ \ \ \ \ | |/ / / / / / |/| | | | | | repository: add a getter and remove function for git's prepared message
| * | | | | | repository: add a getter and remove function for git's prepared messageCarlos Martín Nieto2012-08-011-0/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The 'git revert/cherry-pick/merge -n' commands leave .git/MERGE_MSG behind so that git-commit can find it. As we don't yet support these operations, users who are shelling out to let git perform these operations haven't had a convenient way to get this message. These functions allow the user to retrieve the message and remove it when she's created the commit.
* | | | | | | Add function to query for compile time settings.Sascha Cunz2012-08-011-0/+23
|/ / / / / /
* | | | | | Merge pull request #833 from carlosmn/odb-oneVicent Martí2012-07-312-0/+14
|\ \ \ \ \ \ | | | | | | | | | | | | | | odb: allow creating an ODB backend from a packfile index
| * | | | | | repo: add git_repository_wrap_odb() to wrap an ODBCarlos Martín Nieto2012-07-211-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Primarily useful when used together with git_odb_backend_one_pack().
| * | | | | | odb: allow creating an ODB backend from a packfile indexCarlos Martín Nieto2012-07-211-0/+1
| | |_|_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | git_odb_backend_one_packfile() allows us to create an ODB backend out of an .idx file.
* | | | | | git_oid_cmp: inline memcmp by hand to optimizeMichael Schubert2012-07-291-1/+25
| |_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git.git uses an inlined hashcmp function instead of memcmp, since it performes much better when comparing hashes (most hashes compared diverge within the first byte). Measurements and rationale for the curious reader: http://thread.gmane.org/gmane.comp.version-control.git/172286
* | | | | Merge pull request #834 from carlosmn/network-callbacksVicent Martí2012-07-272-1/+35
|\ \ \ \ \ | | | | | | | | | | | | Add a struct for network callbacks
| * | | | | Add a struct for network callbacksCarlos Martín Nieto2012-07-212-1/+35
| |/ / / / | | | | | | | | | | | | | | | | | | | | Currently only update_tips is used, but it prepares the way for progress output during download.
* | | | | branch: Add `repository` argument to `create`Vicent Marti2012-07-271-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | Yes, we can get the repository from the owner of the object, but having it marked explicitly makes the API more consistent.
* | | | | Merge remote-tracking branch 'nulltoken/topic/branch-rework' into developmentVicent Marti2012-07-272-29/+52
|\ \ \ \ \
| * | | | | refs: drop git_reference_remote_tracking_from_branch()nulltoken2012-07-241-21/+0
| | | | | |