summaryrefslogtreecommitdiff
path: root/include
Commit message (Collapse)AuthorAgeFilesLines
* buf: deprecate git_buf as a public typeethomson/userbufEdward Thomson2020-05-2915-161/+64
| | | | | | | | | | | | | | | The `git_buf` type is now no longer a publicly available structure, and the `git_buf` family of functions are no longer exported. The deprecation layer adds a typedef for `git_buf` (as `git_userbuf`) and macros that define `git_buf` functions as `git_userbuf` functions. This provides API (but not ABI) compatibility with libgit2 1.0's buffer functionality. Within libgit2 itself, we take care to avoid including those deprecated typedefs and macros, since we want to continue using the `git_buf` type and functions unmodified. Therefore, a `GIT_DEPRECATE_BUF` guard now wraps the buffer deprecation layer. libgit2 will define that.
* filter: user-facing functions write to a userbufEdward Thomson2020-05-293-13/+14
|
* merge: user-facing functions write to a userbufEdward Thomson2020-05-291-1/+1
|
* submodule: user-facing functions write to a userbufEdward Thomson2020-05-291-1/+1
|
* packbuilder: user-facing functions write to a userbufEdward Thomson2020-05-292-2/+2
|
* refspec: user-facing functions write to a userbufEdward Thomson2020-05-291-3/+3
|
* object: user-facing functions write to a userbufEdward Thomson2020-05-291-1/+1
|
* diff: user-facing functions write to a userbufEdward Thomson2020-05-291-6/+6
|
* notes: user-facing functions write to a userbufEdward Thomson2020-05-291-1/+1
|
* message: user-facing functions write to a userbufEdward Thomson2020-05-291-2/+3
|
* remote: user-facing functions write to a userbufEdward Thomson2020-05-291-2/+2
|
* tree: user-facing functions write to a userbufEdward Thomson2020-05-291-2/+2
|
* worktree: user-facing functions write to a userbufEdward Thomson2020-05-291-1/+2
|
* repository: user-facing functions write to a userbufEdward Thomson2020-05-291-7/+8
|
* settings: user-facing functions write to a userbufEdward Thomson2020-05-291-2/+2
|
* describe: user-facing functions write to a userbufEdward Thomson2020-05-291-1/+1
|
* commit: user-facing functions write to a userbufEdward Thomson2020-05-291-4/+4
|
* branch: user-facing functions write to a userbufEdward Thomson2020-05-281-3/+3
|
* blob: user-facing functions write to a userbufEdward Thomson2020-05-282-5/+7
|
* config: user-facing functions write to a userbufEdward Thomson2020-05-281-12/+12
|
* diff: user-facing functions write to a userbufEdward Thomson2020-05-282-9/+11
|
* userbuf: provide a user-facing buffer structEdward Thomson2020-05-281-0/+78
| | | | | | | Introduce a new user-facing buffer struct that is compatible with `git_buf`. This will allow us to keep our `git_buf` implementation private, to disentangle the notion of public and private types. But since it's compatible, it's trivially castable.
* Introduce GIT_ASSERT macrosEdward Thomson2020-05-111-1/+2
| | | | | | | | | | | | Provide macros to replace usages of `assert`. A true `assert` is punishing as a library. Instead we should do our best to not crash. GIT_ASSERT_ARG(x) will now assert that the given argument complies to some format and sets an error message and returns `-1` if it does not. GIT_ASSERT(x) is for internal usage, and available as an internal consistency check. It will set an error message and return `-1` in the event of failure.
* blame: add option to ignore whitespace changesCarl Schwan2020-04-141-0/+2
|
* version.h: bump version to v1.0.0Patrick Steinhardt2020-03-281-4/+4
|
* Merge pull request #5464 from pks-t/pks/refdb-backend-docsPatrick Steinhardt2020-03-261-2/+109
|\ | | | | refdb_backend: improve callback documentation
| * refdb_backend: improve callback documentationPatrick Steinhardt2020-03-261-2/+109
| | | | | | | | | | | | | | The callbacks are currently sparsely documented, making it really hard to implement a new backend without taking a look at the existing refdb_fs backend. Add documentation to make this task hopefully easier to achieve.
* | credentials: provide backcompat for opaque structsethomson/cred_deprecationEdward Thomson2020-03-261-0/+7
|/ | | | | | The credential structures are now opaque and defined in `sys/credential.h`. However, we should continue to provide them for backward compatibility, unless `GIT_DEPRECATED_HARD` is set.
* repository: improve commondir docsJosh Bleecher Snyder2020-03-071-4/+5
| | | | Fixes #5428
* version: update the version number to v0.99Edward Thomson2020-02-191-3/+3
| | | | | | This commit also switches our SOVERSION to be "$MAJOR.$MINOR" instead of "$MINOR", only. This is in preparation of v1.0, where the previous scheme would've stopped working in an obvious way.
* Merge pull request #5336 from libgit2/ethomson/credtypePatrick Steinhardt2020-01-3011-184/+290
|\ | | | | cred: change enum to git_credential_t and GIT_CREDENTIAL_*
| * credential: change git_cred to git_credentialethomson/credtypeEdward Thomson2020-01-2611-184/+290
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We avoid abbreviations where possible; rename git_cred to git_credential. In addition, we have standardized on a trailing `_t` for enum types, instead of using "type" in the name. So `git_credtype_t` has become `git_credential_t` and its members have become `GIT_CREDENTIAL` instead of `GIT_CREDTYPE`. Finally, the source and header files have been renamed to `credential` instead of `cred`. Keep previous name and values as deprecated, and include the new header files from the previous ones.
* | git_libgit2_version: return an intethomson/no_voidEdward Thomson2020-01-241-1/+2
| | | | | | | | | | Stop returning a void for functions, future-proofing them to allow them to fail.
* | error functions: return an intEdward Thomson2020-01-241-1/+2
| | | | | | | | | | Stop returning a void for functions, future-proofing them to allow them to fail.
* | revwalk functions: return an intEdward Thomson2020-01-241-3/+7
| | | | | | | | | | Stop returning a void for functions, future-proofing them to allow them to fail.
* | mempack functions: return an intEdward Thomson2020-01-241-1/+2
| | | | | | | | | | Stop returning a void for functions, future-proofing them to allow them to fail.
* | repository functions: return an intEdward Thomson2020-01-241-5/+12
| | | | | | | | | | Stop returning a void for functions, future-proofing them to allow them to fail.
* | index functions: return an intEdward Thomson2020-01-241-2/+4
| | | | | | | | | | Stop returning a void for functions, future-proofing them to allow them to fail.
* | remote functions: return an intEdward Thomson2020-01-241-2/+4
| | | | | | | | | | Stop returning a void for functions, future-proofing them to allow them to fail.
* | tree functions: return an intEdward Thomson2020-01-241-2/+4
| | | | | | | | | | Stop returning a void for functions, future-proofing them to allow them to fail.
* | oid functions: return an intEdward Thomson2020-01-241-5/+10
| | | | | | | | | | Stop returning a void for functions, future-proofing them to allow them to fail.
* | git_attr_cache_flush: return an intEdward Thomson2020-01-241-1/+4
|/ | | | | Stop returning a void for functions, future-proofing them to allow them to fail.
* http: introduce GIT_ERROR_HTTPethomson/gssapiEdward Thomson2020-01-241-1/+2
| | | | | Disambiguate between general network problems and HTTP problems in error codes.
* httpclient: support expect/continueEdward Thomson2020-01-241-1/+7
| | | | | | | | | | | | | Allow users to opt-in to expect/continue handling when sending a POST and we're authenticated with a "connection-based" authentication mechanism like NTLM or Negotiate. If the response is a 100, return to the caller (to allow them to post their body). If the response is *not* a 100, buffer the response for the caller. HTTP expect/continue is generally safe, but some legacy servers have not implemented it correctly. Require it to be opt-in.
* merge: Return non-const git_repository from git_merge_driver_source_repo ↵Laurence McGlashan2020-01-151-1/+1
| | | | accessor.
* Correct typo in name of referenced parameterRemy Suen2020-01-021-1/+1
| | | Signed-off-by: Remy Suen <remy.suen@gmail.com>
* Merge pull request #5300 from tiennou/fix/branch-documentationPatrick Steinhardt2019-12-131-57/+74
|\ | | | | branch: clarify documentation around branches
| * refs: rename git_reference__set_name to git_reference__reallocEtienne Samson2019-12-131-0/+6
| | | | | | | | | | | | | | | | | | | | | | As git_reference__name will reallocate storage to account for longer names (it's actually allocator-dependent), it will cause all existing pointers to the old object to become dangling, as they now point to freed memory. Fix the issue by renaming to a more descriptive name, and pass a pointer to the actual reference that can safely be invalidated if the realloc succeeds.
| * branch: clarify documentation around branchesEtienne Samson2019-12-071-57/+68
| |
* | stash: make comment match codeJosh Bleecher Snyder2019-12-041-1/+1
|/ | | | There is no git_stash_apply_flags_t above.