summaryrefslogtreecommitdiff
path: root/include/git2
Commit message (Collapse)AuthorAgeFilesLines
* cred: add a free function wrappercmn/smart-callbacksCarlos Martín Nieto2015-08-191-0/+11
|
* transport: provide a way to get the callbacksCarlos Martín Nieto2015-08-191-0/+22
| | | | | | | | libgit2 implementations of smart subtransports can simply reach through the structure, but external implementors cannot. Add these two functions as a way for the smart subtransports to get the callbacks as set by the user.
* config: perform unlocking via git_transactioncmn/config-txCarlos Martín Nieto2015-08-121-16/+7
| | | | | This makes the API for commiting or discarding changes the same as for references.
* config: expose locking via the main APICarlos Martín Nieto2015-08-121-0/+27
| | | | | | | | | This lock/unlock pair allows for the cller to lock a configuration file to avoid concurrent operations. It also allows for a transactional approach to updating a configuration file. If multiple updates must be made atomically, they can be done while the config is locked.
* config: implement basic transactional supportCarlos Martín Nieto2015-08-121-0/+14
| | | | | | | When a configuration file is locked, any updates made to it will be done to the in-memory copy of the file. This allows for multiple updates to happen while we hold the lock, preventing races during complex config-file manipulation.
* Make giterr_detach no longer publicMichael Procter2015-08-031-12/+0
|
* Merge pull request #3332 from phatblat/ben/doc-warningsCarlos Martín Nieto2015-08-015-8/+8
|\ | | | | Resolve documentation warnings
| * Fix remaining documentation warningsBen Chatelain2015-07-272-2/+2
| |
| * Use correct Doxygen trailing comment syntaxBen Chatelain2015-07-271-4/+4
| |
| * Fix @param names in doc commentsBen Chatelain2015-07-273-3/+3
| |
* | Merge pull request #3303 from libgit2/cmn/index-add-submoduleEdward Thomson2015-07-241-0/+1
|\ \ | | | | | | Allow adding a submodule through git_index_add_bypath
| * | errors: add EDIRECTORYCarlos Martín Nieto2015-07-121-0/+1
| | | | | | | | | | | | | | | This is to be returned when the operation which the user asked for is not possible to do on a directory.
* | | Merge pull request #3305 from libgit2/cmn/reflog-del-backendEdward Thomson2015-07-241-2/+3
|\ \ \ | |_|/ |/| | refdb: delete a ref's reflog upon deletion
| * | refdb: delete a ref's reflog upon deletioncmn/reflog-del-backendCarlos Martín Nieto2015-07-121-2/+3
| |/ | | | | | | | | | | Removing a reflog upon ref deletion is something which only some backends might wish to do. Backends which are database-backed may wish to archive a reflog, log-based ones may not need to do anything.
* | Document git_fetch_options struct and fix typo.Ryan Roden-Corrent2015-07-201-1/+9
|/ | | | | | | | git_fetch_options was missing from the API docs because it lacked a documentation comment above the struct declaration. I used the git_checkout_options docstring as a template. Also fixes a typo in git_remote_prune_refs (remote, not reamote).
* git_cert: child types use proper base typeEdward Thomson2015-07-101-21/+14
|
* Merge pull request #3281 from ethomson/wildcard_filtersCarlos Martín Nieto2015-07-091-1/+4
|\ | | | | filters: custom filters with wildcard attributes
| * filters: custom filters with wildcard attributesEdward Thomson2015-07-011-1/+4
| | | | | | | | | | | | Allow custom filters with wildcard attributes, so that clients can support some random `filter=foo` in a .gitattributes and look up the corresponding smudge/clean commands in the configuration file.
* | Merge pull request #3277 from git-up/git_diff_index_to_indexCarlos Martín Nieto2015-07-071-0/+19
|\ \ | | | | | | Added git_diff_index_to_index()
| * | Added git_diff_index_to_index()Pierre-Olivier Latour2015-06-301-0/+19
| | |
* | | filter: add docs for streaming filterscmn/filter-docCarlos Martín Nieto2015-07-031-2/+35
| | | | | | | | | | | | | | | These functions are available on the public API but don't have any documentation, so they don't appear on the API reference. Fix that.
* | | submodule: completely remove reload_allCarlos Martín Nieto2015-07-011-11/+0
|/ / | | | | | | | | | | | | | | The function was removed, but its declaration and changelog entry about its removal were forgotten. The comment in the test doesn't make any sense as the function doesn't exist anymore, so get rid of it as well.
* | Bump version to 0.23.0 and SOVERSION to 23Carlos Martín Nieto2015-06-281-3/+3
| |
* | Merge pull request #3259 from ethomson/stash_apply_arghCarlos Martín Nieto2015-06-261-0/+1
|\ \ | |/ |/| Stash apply: stage new files even when not updating the index
| * stash: don't allow apply with staged changesEdward Thomson2015-06-251-0/+1
| |
* | Merge pull request #3255 from libgit2/cmn/rename-unspecifiedEdward Thomson2015-06-253-6/+6
|\ \ | |/ |/| Rename FALLBACK to UNSPECIFIED
| * Rename FALLBACK to UNSPECIFIEDcmn/rename-unspecifiedCarlos Martín Nieto2015-06-253-6/+6
| | | | | | | | | | Fallback describes the mechanism, while unspecified explains what the user is thinking.
* | Merge pull request #3246 from libgit2/cmn/dont-grow-borrowedEdward Thomson2015-06-252-6/+5
|\ \ | |/ |/| Don't allow growing borrowed buffers
| * errors: introduce EINVALIDCarlos Martín Nieto2015-06-241-0/+1
| | | | | | | | | | We've been using EINVALIDSPEC for a while to mean this, but that name is too specific. Introduce this to be more explicit.
| * blob: don't recomment using git_buf_growCarlos Martín Nieto2015-06-241-6/+4
| | | | | | | | | | | | | | | | | | We currently recommend using `git_buf_grow` in order to make a buffer make an owned copy of the memory it points to. This is not behaviour we should encourage, so remove this recommendation. The function itself is not changed, as we need to remain compatible, but it will be changed not to allow usage on borrowed buffers.
* | Merge pull request #3097 from libgit2/cmn/submodule-config-stateCarlos Martín Nieto2015-06-243-83/+44
|\ \ | | | | | | Remove run-time configuration settings from submodules
| * | submodule: remove the RESET enum valuescmn/submodule-config-stateCarlos Martín Nieto2015-06-222-9/+1
| | | | | | | | | | | | | | | These are not useful anymore, as we don't affect the instance's configuration.
| * | submodule: get rid of `_save()`Carlos Martín Nieto2015-06-221-14/+0
| | | | | | | | | | | | | | | We no longer have any setters which affect an instance, so `git_submodule_save()` is no longer relevant.
| * | submodule: make `_set_url()` affect the configurationCarlos Martín Nieto2015-06-221-7/+5
| | | | | | | | | | | | With this one, we can get rid of the edit_and_save test.
| * | submodule: make `_set_branch()` affect the configurationCarlos Martín Nieto2015-06-221-8/+5
| | |
| * | submodule: make `_set_update_fetch_recurse_submodules()` affect the configCarlos Martín Nieto2015-06-221-7/+7
| | | | | | | | | | | | | | | | | | Similarly to the other ones. In this test we copy over testing `RECURSE_YES` which shows an error in our handling of the `YES` variant which we may have to port to the rest.
| * | submodule: make `_set_update()` affect the configurationCarlos Martín Nieto2015-06-221-13/+8
| | | | | | | | | | | | | | | Moving on with the removal of runtime-changing variables, the update setting for a remote is whatever it was when it was looked up.
| * | submodule: add an ignore option to statusCarlos Martín Nieto2015-06-223-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This lets us specify in the status call which ignore rules we want to use (optionally falling back to whatever the submodule has in its configuration). This removes one of the reasons for having `_set_ignore()` set the value in-memory. We re-use the `IGNORE_RESET` value for this as it is no longer relevant but has a similar purpose to `IGNORE_FALLBACK`. Similarly, we remove `IGNORE_DEFAULT` which does not have use outside of initializers and move that to fall back to the configuration as well.
| * | submodule: don't let status change an existing instanceCarlos Martín Nieto2015-06-221-4/+5
| | | | | | | | | | | | | | | | | | As submodules are becomes more like values, we should not let a status check to update its properties. Instead of taking a submodule, have status take a repo and submodule name.
| * | submodule: make set_ignore() affect the configurationCarlos Martín Nieto2015-06-221-16/+8
| | | | | | | | | | | | | | | Instead of affecting a particular instance, make it change the configuration.
* | | curl: extract certificate informationCarlos Martín Nieto2015-06-241-0/+12
| | | | | | | | | | | | | | | | | | The information is exposed by curl for some crypto libraries in the form of name:content strings. We can't do much more than return this information.
* | | stream: add support for setting a proxyCarlos Martín Nieto2015-06-241-0/+2
| |/ |/| | | | | | | | | | | | | If the stream claims to support this feature, we can let the transport set the proxy. We also set HTTPPROXYTUNNEL option so curl can create a tunnel through the proxy which lets us create our own TLS session (if needed).
* | Merge pull request #3131 from urkud/const-charEdward Thomson2015-06-231-1/+1
|\ \ | | | | | | Add `const` qualifier
| * | Add `const` qualifierYury G. Kudryashov2015-05-151-1/+1
| | | | | | | | | | | | | | | | | | This fixes a warning in `examples/describe.c` without breaking the main build. OTOH, I'm not sure if this is an API-compatible change.
* | | commit: allow retrieving an arbitrary header fieldcmn/commit-header-fieldCarlos Martín Nieto2015-06-221-0/+11
| |/ |/| | | | | | | | | This allows the user to look up fields which we don't parse in libgit2, and allows them to access gpgsig or mergetag fields if they wish to check the signature.
* | index: use the checksum to check whether it's been modifiedCarlos Martín Nieto2015-06-191-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | We currently use a timetamp to check whether an index file has been modified since we last read it, but this is racy. If two updates happen in the same second and we read after the first one, we won't detect the second one. Instead read the SHA-1 checksum of the file, which are its last 20 bytes which gives us a sure-fire way to detect whether the file has changed since we last read it. As we're now keeping track of it, expose an accessor to this data.
* | diff: introduce binary diff callbacksEdward Thomson2015-06-121-0/+55
| | | | | | | | | | | | | | Introduce a new binary diff callback to provide the actual binary delta contents to callers. Create this data from the diff contents (instead of directly from the ODB) to support binary diffs including the workdir, not just things coming out of the ODB.
* | Merge pull request #3155 from mgorny/userpass-constCarlos Martín Nieto2015-06-111-2/+2
|\ \ | | | | | | cred_helpers: Add 'const' qualifiers to git_cred_userpass_payload
| * | cred_helpers: Add 'const' qualifiers to git_cred_userpass_payloadMichał Górny2015-05-241-2/+2
| | | | | | | | | | | | | | | | | | Make both username & password in git_cred_userpass_payload 'const'. The values are not altered anywhere, and the extra qualifier allows clients to assign 'const' values there.
* | | Introduce `git_filter_list_contains`Edward Thomson2015-06-101-0/+16
| | | | | | | | | | | | | | | `git_filter_list_contains` can be used to query a filter list to determine if a given filter will be run.