summaryrefslogtreecommitdiff
path: root/include/git2
Commit message (Collapse)AuthorAgeFilesLines
* config: remove the refresh function and backend fieldcmn/config-refresh-removeCarlos Martín Nieto2014-10-232-15/+0
| | | | | | We have been refreshing on read and write for a while now, so git_config_refresh() is at best a no-op, and might just end up wasting cycles.
* Update some documentationCarlos Martín Nieto2014-10-184-27/+47
|
* Move un-namespaced constant to internal headerRussell Belfer2014-10-101-2/+0
| | | | FLAG_BITS only seems to be used internally
* Merge pull request #2593 from libgit2/cmn/remote-delete-nameEdward Thomson2014-10-101-2/+3
|\ | | | | remote: accept a repository and remote name for deletion
| * remote: accept a repository and remote name for deletioncmn/remote-delete-nameCarlos Martín Nieto2014-09-301-2/+3
| | | | | | | | | | | | | | | | We don't need the remote loaded, and the function extracted both of these from the git_remote in order to do its work, so let's remote a step and not ask for the loaded remote at all. This fixes #2390.
* | Merge pull request #2575 from cirosantilli/factor-struct-typedefCarlos Martín Nieto2014-10-101-6/+4
|\ \ | | | | | | [factor] Join typedef and struct definitions in single file.
| * | Join typedef and struct definitions in single file.Ciro Santilli2014-09-241-6/+4
| | |
* | | Merge pull request #2588 from swansontec/ssl-cert-path2Carlos Martín Nieto2014-10-101-1/+13
|\ \ \ | | | | | | | | Add support for setting the SSL CA location
| * | | Add support for setting the SSL CA locationWilliam Swanson2014-09-301-1/+13
| | |/ | |/| | | | | | | | | | This allows users to specify self-signed certificates, or to provide their own certificate stores on limited platforms such as mobile phones.
* | | Merge pull request #2499 from csware/hard-reset-checkout-callbacksCarlos Martín Nieto2014-10-101-0/+5
|\ \ \ | | | | | | | | Allow to propagate checkout callbacks to git HARD reset
| * | | Allow to propagate checkout callbacks to git HARD resetSven Strickroth2014-08-031-0/+5
| | | | | | | | | | | | | | | | Signed-off-by: Sven Strickroth <email@cs-ware.de>
* | | | Merge pull request #2574 from csware/hostname-for-certificate_check_cbEdward Thomson2014-10-101-1/+2
|\ \ \ \ | | | | | | | | | | Provide host name to certificate_check_cb
| * | | | Provide host name to certificate_check_cbSven Strickroth2014-09-221-1/+2
| | |/ / | |/| | | | | | | | | | Signed-off-by: Sven Strickroth <email@cs-ware.de>
* | | | Treat an empty list of refspecs the same as a NULL value.Arthur Schreiber2014-10-101-3/+3
| | | |
* | | | Merge pull request #2592 from libgit2/cmn/describeCarlos Martín Nieto2014-10-093-0/+165
|\ \ \ \ | | | | | | | | | | Implement git-describe
| * | | | describe: document the APIcmn/describeCarlos Martín Nieto2014-09-301-3/+71
| | | | |
| * | | | describe: rename git_describe_opts to git_describe_optionsCarlos Martín Nieto2014-09-301-5/+9
| | | | | | | | | | | | | | | | | | | | And implement the option init functions for this and the format options.
| * | | | describe: implement describing the workdirCarlos Martín Nieto2014-09-301-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we describe the workdir, we perform a describe on HEAD and then check to see if the worktree is dirty. If it is and we have a suffix string, we append that to the buffer.
| * | | | describe: split into gather and format stepsCarlos Martín Nieto2014-09-301-4/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of printing out to the buffer inside the information-gathering phase, write the data to a intermediate result structure. This allows us to split the options into gathering options and formatting options, simplifying the gathering code.
| * | | | describe: rename _object() to _commit()Carlos Martín Nieto2014-09-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | We don't describe arbitrary object, so let's give it the name of the one object type we accept.
| * | | | Merge remote-tracking branch 'upstream/master' into cmn/describeCarlos Martín Nieto2014-09-3041-728/+1247
| |\ \ \ \ | | |/ / /
| * | | | object: introduce git_describe_object()nulltoken2014-04-303-0/+69
| | | | |
* | | | | Merge pull request #2448 from libgit2/cmn/reference-transactionEdward Thomson2014-10-094-1/+128
|\ \ \ \ \ | | | | | | | | | | | | Introduce reference transactions
| * | | | | transaction: rename lock() to lock_ref()cmn/reference-transactionCarlos Martín Nieto2014-10-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This leaves space for future expansion to locking other resources without having to change the API for references.
| * | | | | transaction: add documentationCarlos Martín Nieto2014-09-301-2/+88
| | | | | |
| * | | | | Introduce reference transactionsCarlos Martín Nieto2014-09-303-0/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A transaction allows you to lock multiple references and set up changes for them before applying the changes all at once (or as close as the backend supports). This can be used for replication purposes, or for making sure some operations run when the reference is locked and thus cannot be changed.
| * | | | | reflog: constify byindexCarlos Martín Nieto2014-09-301-1/+1
| | |/ / / | |/| | |
* | | | | Merge pull request #2462 from libgit2/cmn/remote-fetch-refsEdward Thomson2014-10-091-1/+7
|\ \ \ \ \ | | | | | | | | | | | | Implement opportunistic ref updates
| * | | | | remote: allow overriding the refspecs for download and fetchCarlos Martín Nieto2014-09-301-1/+7
| |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With opportunistic ref updates, git has introduced the concept of having base refspecs *and* refspecs that are active for a particular fetch. Let's start by letting the user override the refspecs for download.
* | | | | Add git_merge_bases_many.Arthur Schreiber2014-10-091-0/+15
| | | | |
* | | | | hashsig: Export as a `sys` headervmg/hashsigVicent Marti2014-10-011-0/+76
|/ / / /
* | | | Merge pull request #2464 from libgit2/cmn/host-cert-infoVicent Marti2014-09-175-11/+109
|\ \ \ \ | | | | | | | | | | Provide a callback for certificate validation
| * | | | ssh: expose both hashesCarlos Martín Nieto2014-09-161-9/+16
| | | | | | | | | | | | | | | | | | | | | | | | | The user may have the data hashed as MD5 or SHA-1, so we should provide both types for consumption.
| * | | | ssh: provide our own types for host key lengthsCarlos Martín Nieto2014-09-161-2/+12
| | | | | | | | | | | | | | | | | | | | | | | | | Instead of using the libssh2 defines, provide our own, which eases usage as we do not need to check whether libgit2 was built with libssh2 or not.
| * | | | net: use only structs to pass information about certCarlos Martín Nieto2014-09-162-3/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of spreading the data in function arguments, some of which aren't used for ssh and having a struct only for ssh, use a struct for both, using a common parent to pass to the callback.
| * | | | Merge remote-tracking branch 'upstream/master' into cmn/host-cert-infoCarlos Martín Nieto2014-09-165-8/+82
| |\ \ \ \ | | | |_|/ | | |/| |
| * | | | net: remove support for outright ignoring certificatesCarlos Martín Nieto2014-09-162-11/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This option make it easy to ignore anything about the server we're connecting to, which is bad security practice. This was necessary as we didn't use to expose detailed information about the certificate, but now that we do, we should get rid of this. If the user wants to ignore everything, they can still provide a callback which ignores all the information passed.
| * | | | transport: move the cert type enum to types.hCarlos Martín Nieto2014-09-162-17/+16
| | | | | | | | | | | | | | | | | | | | This should make the mingw compiler happy.
| * | | | transport: always call the certificate check callbackCarlos Martín Nieto2014-09-161-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We should let the user decide whether to cancel the connection or not regardless of whether our checks have decided that the certificate is fine. We provide our own assessment to the callback to let the user fall back to our checks if they so desire.
| * | | | http: send the DER-encoded cert to the callbackCarlos Martín Nieto2014-09-162-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of the parsed data, we can ask OpenSSL to give us the DER-encoded version of the certificate, which the user can then parse and validate.
| * | | | Provide a callback for certificate validationCarlos Martín Nieto2014-09-165-0/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the certificate validation fails (or always in the case of ssh), let the user decide whether to allow the connection. The data structure passed to the user is the native certificate information from the underlying implementation, namely OpenSSL or WinHTTP.
* | | | | Fix attribute lookup in index for bare reposrb/attr-with-bareRussell Belfer2014-09-151-0/+13
| |/ / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When using a bare repo with an index, libgit2 attempts to read files from the index. It caches those files based on the path to the file, specifically the path to the directory that contains the file. If there is no working directory, we use `git_path_dirname_r` to get the path to the containing directory. However, for the `.gitattributes` file in the root of the repository, this ends up normalizing the containing path to `"."` instead of the empty string and the lookup the `.gitattributes` data fails. This adds a test of attribute lookups on bare repos and also fixes the problem by simply rewriting `"."` to be `""`.
* | | | Merge pull request #2543 from libgit2/cmn/known-transportsVicent Marti2014-09-031-8/+5
|\ \ \ \ | | | | | | | | | | Clean up transport lookup
| * | | | remote: get rid of git_remote_valid_url()Carlos Martín Nieto2014-08-311-8/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It does the same as git_remote_supported_url() but has a name which implies we'd check the URL for correctness while we're simply looking at the scheme and looking it up in our lists. While here, fix up the tests so we check all the combination of what's supported.
* | | | | Introduce option to use relative paths for repository work directoryjamill/relative_gitlinkJameson Miller2014-09-022-0/+21
|/ / / / | | | | | | | | | | | | | | | | | | | | | | | | Teach git_repository_init_ext to use relative paths for the gitlink to the work directory. This is used when creating a sub repository where the sub repository resides in the parent repository's .git directory.
* | | | Merge pull request #2481 from libgit2/cmn/oidarrayVicent Marti2014-08-292-0/+56
|\ \ \ \ | |/ / / |/| | | merge: expose multiple merge bases
| * | | merge: expose multiple merge basescmn/oidarrayCarlos Martín Nieto2014-07-272-0/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We always calculate multiple merge bases, but up to now we had only exposed the "best" merge base. Introduce git_oidarray which analogously to git_strarray lets us return multiple ids.
* | | | Merge remote-tracking branch 'upstream/master' into cmn/ssh-retryCarlos Martín Nieto2014-08-2716-480/+560
|\ \ \ \
| * \ \ \ Merge pull request #2528 from libgit2/vmg/tostr_sVicent Marti2014-08-181-4/+8
| |\ \ \ \ | | | | | | | | | | | | Export `git_oid_tostr_s` instead of `_allocfmt`
| | * | | | oid: Export `git_oid_tostr_s` instead of `_allocfmt`vmg/tostr_sVicent Marti2014-08-181-4/+8
| | | |_|/ | | |/| | | | | | | | | | | | | | | | | | | | | | The old `allocfmt` is of no use to callers, as they are not able to free the returned buffer. Export a new API that returns a static string that doesn't need to be freed.