summaryrefslogtreecommitdiff
path: root/include
Commit message (Collapse)AuthorAgeFilesLines
* transport: provide a getter for the proxy optionscmn/transport-get-proxyCarlos Martín Nieto2017-04-171-0/+10
| | | | | | | | As with the callbacks, third-party implementations of smart subtransports cannot reach into the opaque struct and thus cannot know what options the user set. Add a getter for these options to copy the proxy options into something external implementors can use.
* Correct typos that reference a non-existing fileRemy Suen2017-04-031-2/+2
| | | | | There are references to odb_backends.h when the file is actually named odb_backend.h and in the sys folder.
* Merge pull request #4163 from pks-t/pks/submodules-with-worktreesEdward Thomson2017-03-221-0/+12
|\ | | | | Worktree fixes
| * worktree: implement `git_worktree_open_from_repository`Patrick Steinhardt2017-03-171-0/+12
| | | | | | | | | | | | | | | | | | While we already provide functionality to look up a worktree from a repository, we cannot do so the other way round. That is given a repository, we want to look up its worktree if it actually exists. Getting the worktree of a repository is useful when we want to get certain meta information like the parent's location, getting the locked status, etc.
* | Merge pull request #4030 from libgit2/ethomson/fsyncEdward Thomson2017-03-222-1/+9
|\ \ | | | | | | fsync all the things
| * | fsync: call it "synchronous" object writingEdward Thomson2017-02-281-2/+2
| | | | | | | | | | | | | | | Rename `GIT_OPT_ENABLE_SYNCHRONIZED_OBJECT_CREATION` -> `GIT_OPT_ENABLE_SYNCHRONOUS_OBJECT_CREATION`.
| * | Add `ENABLE_SYNCHRONIZED_OBJECT_CREATION` optionEdward Thomson2017-02-281-0/+8
| | | | | | | | | | | | Allow users to enable `SYNCHRONIZED_OBJECT_CREATION` with a setting.
| * | odb_loose: actually honor the fsync optionEdward Thomson2017-02-281-1/+1
| | | | | | | | | | | | | | | We've had an fsync option for a long time, but it was "ignored". Stop ignoring it.
* | | Use proper documentation tagsRemy Suen2017-03-221-6/+6
| | | | | | | | | | | | | | | git_cred_acquire_cb isn't using the standard @param and @return tags. This is causing the generated documentation to not be formatted properly.
* | | Fix typo in remote.h APIRemy Suen2017-03-201-1/+1
| | |
* | | merge_driver: fix const-correctness for source gettersPatrick Steinhardt2017-03-151-5/+5
| |/ |/|
* | hash: include sha1collisiondetectionEdward Thomson2017-03-031-1/+2
|/ | | | | Include the SHA1 collision attack detection library from https://github.com/cr-marcstevens/sha1collisiondetection
* Minor comment fixDavid Catmull2017-02-161-6/+7
|
* Merge pull request #4122 from pks-t/pks/signature-dbl-freeEdward Thomson2017-02-131-3/+6
|\ | | | | Signature cleanups
| * commit: clear user-provided buffersPatrick Steinhardt2017-02-131-3/+6
| | | | | | | | | | | | | | | | | | | | The functions `git_commit_header_field` and `git_commit_extract_signature` both receive buffers used to hand back the results to the user. While these functions called `git_buf_sanitize` on these buffers, this is not the right thing to do, as it will simply initialize or zero-terminate passed buffers. As we want to overwrite contents, we instead have to call `git_buf_clear` to completely reset them.
* | Merge pull request #4115 from gsaralms/users/gsaral/optionalOfsDeltaEdward Thomson2017-02-131-0/+11
|\ \ | |/ |/| Changes to provide option to turn off/on ofs_delta
| * Changes to provide option to turn off/on ofs_deltaGaurav Saral2017-02-101-0/+11
| | | | | | | | This change provides an option in git_libgit2_opt_t which can be used in git_libgit2_opts to turn off/on ofs_delta capability in libGit2
* | worktree: extract git_worktree_is_prunablePatrick Steinhardt2017-02-131-0/+18
| |
* | branch: implement `git_branch_is_checked_out`Patrick Steinhardt2017-02-131-0/+12
| | | | | | | | | | | | | | | | Implement a new function that is able to determine if a branch is checked out in any repository connected to the current repository. In particular, this is required to check if for a given repository and branch, there exists any working tree connected to that repository that is referencing this branch.
* | worktree: implement functions reading HEADPatrick Steinhardt2017-02-132-1/+26
| | | | | | | | | | | | Implement `git_repository_head_for_worktree` and `git_repository_head_detached_for_worktree` for directly accessing a worktree's HEAD without opening it as a `git_repository` first.
* | worktree: implement `git_worktree_prune`Patrick Steinhardt2017-02-131-0/+26
| | | | | | | | | | | | | | Implement the `git_worktree_prune` function. This function can be used to delete working trees from a repository. According to the flags passed to it, it can either delete the working tree's gitdir only or both gitdir and the working directory.
* | worktree: implement locking mechanismsPatrick Steinhardt2017-02-131-0/+36
| | | | | | | | | | | | Working trees support locking by creating a file `locked` inside the tree's gitdir with an optional reason inside. Support this feature by adding functions to get and set the locking status.
* | worktree: implement `git_worktree_add`Patrick Steinhardt2017-02-131-0/+15
| | | | | | | | | | Implement the `git_worktree_add` function which can be used to create new working trees for a given repository.
* | worktree: implement `git_worktree_validate`Patrick Steinhardt2017-02-132-0/+13
| | | | | | | | | | | | Add a new function that checks wether a given `struct git_worktree` is valid. The validation includes checking if the gitdir, parent directory and common directory are present.
* | worktree: implement `git_repository_open_from_worktree`Patrick Steinhardt2017-02-131-0/+11
| | | | | | | | | | Add function `git_repository_open_from_worktree`, which allows to open a `git_worktree` as repository.
* | worktree: introduce `struct git_worktree`Patrick Steinhardt2017-02-132-0/+20
| | | | | | | | | | | | | | Introduce a new `struct git_worktree`, which holds information about a possible working tree connected to a repository. Introduce functions to allow opening working trees for a repository.
* | worktree: implement `git_worktree_list`Patrick Steinhardt2017-02-131-0/+37
| | | | | | | | | | | | Add new module for working trees with the `git_worktree_list` function. The function lists names for all working trees of a certain repository.
* | repository: introduce is_worktree variablePatrick Steinhardt2017-02-131-0/+8
| |
* | repository: add function to retrieve paths for repo itemsPatrick Steinhardt2017-02-131-0/+36
| |
* | repository: introduce commondir variablePatrick Steinhardt2017-02-131-0/+11
| | | | | | | | | | | | | | | | | | The commondir variable stores the path to the common directory. The common directory is used to store objects and references shared across multiple repositories. A current use case is the newly introduced `git worktree` feature, which sets up a separate working copy, where the backing git object store and references are pointed to by the common directory.
* | Flag optional parameters for apply and popRemy Suen2017-02-091-2/+2
|/ | | | The options parameter in both git_stash_apply and git_stash_pop can be NULL. They should be flagged as such in the documentation.
* Flag checkout_opts in git_reset as optionalRemy Suen2017-02-051-1/+1
| | | | The check_outs argument can be NULL and should be flagged accordingly in the header file.
* Flag given_opts in git_revert as optionalRemy Suen2017-02-041-1/+1
| | | | The given_opts argument can actually be NULL and thus should be flagged accordingly in the header file.
* Update docs for git_oid_fromstrn and pMatthew Plough2017-01-271-5/+4
|
* parameter 'id' not found in the function declarationEtienne Samson2017-01-231-1/+1
|
* Merge branch 'pr/3912'Edward Thomson2017-01-211-0/+10
|\
| * symbolic ref target validation: fixupsEdward Thomson2017-01-211-10/+8
| | | | | | | | Fixups requested in #3912.
| * Make symbolic ref target validation optionalRichard Ipsum2016-08-271-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Introduce GIT_OPT_ENABLE_SYMBOLIC_REF_TARGET_VALIDATION option. Setting this option to 0 allows validation of a symbolic ref's target to be bypassed. This option is enabled by default. This mechanism is added primarily to address a discrepancy between git behaviour and libgit2 behaviour, whereby the former allows the symbolic ref target to carry an arbitrary string and the latter does not, so: $ git symbolic-ref refs/heads/foo bar $ cat .git/refs/heads/foo ref: bar where as attempting the same via libgit2 raises an error: The given reference name 'bar' is not valid this mechanism also allows those that might want to make use of git's more lenient treatment of symbolic ref targets to do so.
* | Merge pull request #3892 from mitesch/shared_bufferEdward Thomson2017-01-211-0/+13
|\ \ | | | | | | Use a shared buffer in calls of git_treebuilder_write to avoid heap contention
| * | write_tree: use shared buffer for writing treesMichael Tesch2016-12-121-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | The function to write trees allocates a new buffer for each tree. This causes problems with performance when performing a lot of actions involving writing trees, e.g. when doing many merges. Fix the issue by instead handing in a shared buffer, which is then re-used across the calls without having to re-allocate between calls.
* | | Merge branch 'master' into pr/3938Edward Thomson2017-01-219-12/+72
|\ \ \
| * | | Allow for caching of submodules.Brock Peabody2017-01-201-0/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added `git_repository_submodule_cache_all` to initialze a cache of submodules on the repository so that operations looking up N submodules are O(N) and not O(N^2). Added a `git_repository_submodule_cache_clear` function to remove the cache. Also optimized the function that loads all submodules as it was itself O(N^2) w.r.t the number of submodules, having to loop through the `.gitmodules` file once per submodule. I changed it to process the `.gitmodules` file once, into a map. Signed-off-by: David Turner <dturner@twosigma.com>
| * | | merge: set default rename thresholdEdward Thomson2017-01-011-1/+2
| | | | | | | | | | | | | | | | | | | | When `GIT_MERGE_FIND_RENAMES` is set, provide a default for `rename_threshold` when it is unset.
| * | | Merge pull request #3980 from tiennou/doc-fixesv0.25.0-rc2v0.25.0Carlos Martín Nieto2016-12-203-5/+17
| |\ \ \ | | | | | | | | | | Documentation fixes
| | * | | transaction: fix documentationEtienne Samson2016-11-011-0/+9
| | | | |
| | * | | remote: fix documentation and indentEtienne Samson2016-11-011-1/+3
| | | | |
| | * | | remote: unused function typedefEtienne Samson2016-11-011-2/+0
| | | | |
| | * | | describe: fix documentationEtienne Samson2016-11-011-2/+5
| | | | |
| * | | | settings: clarify what each value meanscmn/https-cap-no-hardcodeCarlos Martín Nieto2016-12-171-0/+18
| | | | | | | | | | | | | | | | | | | | Most importantly, clarify what it means for HTTPS and SSH to be supported.
| * | | | remote: fix typo in git_fetch_init_options docsJosh Bleecher Snyder2016-12-021-1/+1
| | | | |