|
675251d1
|
2019-03-28T20:35:17
|
|
Merge pull request #5032 from eaigner/checkout-force-safe-docfix
docs: clarify relation of safe and forced checkout strategy
|
|
bbba4805
|
2019-03-25T20:45:58
|
|
docs: clarify relation of safe and forced checkout strategy
|
|
79b26f20
|
2019-03-02T18:21:47
|
|
Merge pull request #5008 from libgit2/ethomson/remote_completion
remote: Rename git_remote_completion_type to _t
|
|
2dd5a429
|
2019-02-25T13:16:13
|
|
remote: Rename git_remote_completion_type to _t
For consistency with other "type" enums, rename
git_remote_completion_type to git_remote_completion_t.
|
|
459ac856
|
2019-02-23T18:42:53
|
|
odb: provide a free function for custom backends
Custom backends can allocate memory when reading objects and providing
them to libgit2. However, if an error occurs in the custom backend
after the memory has been allocated for the custom object but before
it's returned to libgit2, the custom backend has no way to free that
memory and it must be leaked.
Provide a free function that corresponds to the alloc function so that
custom backends have an opportunity to free memory before they return an
error.
|
|
790aae77
|
2019-02-23T18:40:43
|
|
odb: rename git_odb_backend_malloc for consistency
The `git_odb_backend_malloc` name is a system function that is provided
for custom ODB backends and allows them to allocate memory for an ODB
object in the read callback. This is important so that libgit2 can
later free the memory used by an ODB object that was read from the
custom backend.
However, the name _suggests_ that it actually allocates a
`git_odb_backend`. It does not; rename it to make it clear that it
actually allocates backend _data_.
|
|
ca909da5
|
2019-02-21T11:45:23
|
|
remote: deprecate git_push_transfer_progress
Safely deprecate `git_push_transfer_progress`, forwarding it to the new
`git_push_transfer_progress_cb` name.
|
|
59001e83
|
2019-02-21T11:41:19
|
|
remote: rename git_push_transfer_progress callback
The `git_push_transfer_progress` is a callback and as such should be
suffixed with `_cb` for consistency. Rename
`git_push_transfer_progress` to `git_push_transfer_progress_cb`.
|
|
7506d34c
|
2019-02-21T10:38:53
|
|
indexer: deprecate git_transfer_progress
Safely deprecate `git_transfer_progress` and `git_transfer_progress_cb`
types, forwarding them to the new `git_indexer_progress` and
`git_indexer_progress_cb`.
|
|
a1ef995d
|
2019-02-21T10:33:30
|
|
indexer: use git_indexer_progress throughout
Update internal usage of `git_transfer_progress` to
`git_indexer_progreses`.
|
|
975d6722
|
2019-02-21T10:13:29
|
|
indexer: rename git_transfer_progress
The name `git_transfer_progress` does not reflect its true purpose.
It suggests that it's progress for a non-existence `git_transfer`
object, and is used for indexing callbacks more broadly than just
during transfers.
Rename `git_transfer_progress` to `git_indexer_progress`.
|
|
9eb098d8
|
2019-02-21T11:37:04
|
|
Merge pull request #4991 from libgit2/ethomson/inttypes
Remove public 'inttypes.h' header
|
|
247e6d90
|
2019-02-18T07:22:20
|
|
Remove public 'inttypes.h' header
Remove an `inttypes.h` header that is too large in scope, and far too
public.
For Visual Studio 2012 and earlier (ie, `_MSC_VER < 1800`), we do need
to include `stdint.h` in our public headers, for types like `uint32_t`.
Internally, we also need to define `PRId64` as a printf formatting
string when it is not available.
|
|
e6c6d3bb
|
2019-02-17T22:31:37
|
|
Remove `git_time_monotonic`
`git_time_monotonic` was added so that non-native bindings like rugged
could get high-resolution timing for benchmarking. However, this is
outside the scope of libgit2 *and* rugged decided not to use this
function in the first place.
Google suggests that absolutely _nobody_ is using this function and we
don't want to be in the benchmarking business. Remove the function.
|
|
004a3398
|
2019-01-28T18:31:21
|
|
Allow bypassing check '.keep' files using libgit2 option 'GIT_OPT_IGNORE_PACK_KEEP_FILE_CHECK'
|
|
3fe29c4d
|
2019-01-31T19:10:03
|
|
version: 0.28
|
|
9fd9126e
|
2019-01-30T21:19:18
|
|
docs: minor changes
|
|
690e55e0
|
2019-01-04T19:09:42
|
|
repo: split git_repository_open_flag_t options documentation inline
|
|
f6412c26
|
2019-01-15T13:35:41
|
|
transport: enhance documentation
|
|
9e4d421e
|
2019-01-15T11:32:13
|
|
doc: clarify that git_time_t is seconds from the epoch
|
|
9f3a5a64
|
2019-01-23T00:29:03
|
|
deprecation: offer GIT_DEPRECATE_HARD
Users can define `GIT_DEPRECATE_HARD` if they want to remove all
functions that we've "softly" deprecated.
|
|
09e2ea2f
|
2019-01-23T09:44:40
|
|
deprecation: provide docurium deprecation note
Add `@deprecated` to the functions that are, so that they'll appear that
way in docurium.
|
|
53d13fb3
|
2019-01-23T09:42:55
|
|
deprecation: deprecated stream registration in if guard
`git_stream_register_tls` is now deprecated; mark it in an if guard with
the deprecation.
This should not be included in `deprecated.h` since it is an uncommonly
used `sys` header file.
|
|
a7d0d14f
|
2019-01-23T00:07:40
|
|
deprecation: move deprecated bits to deprecated.h
|
|
647dfdb4
|
2019-01-10T22:13:07
|
|
git_error: deprecate error values
Replace the `GITERR` values with a `const int` to deprecate error
values.
|
|
20961b98
|
2018-12-26T14:06:21
|
|
git_error: use full class name in public error API
Move to the `git_error` name in error-related functions, deprecating the
`giterr` functions. This means, for example, that `giterr_last` is now
`git_error_last`. The old names are retained for compatibility.
This only updates the public API; internal API and function usage
remains unchanged.
|
|
1b2af79e
|
2019-01-20T10:49:23
|
|
deprecation: use the enum type in declaration
The C standard does not specify whether an enum is a signed or unsigned
type. Obviously, any enum that includes negative values _must_ be
signed, but if all values are positive then the compiler is free to
choose signed or unsigned.
Thus, by changing the type signatures to `git_object_t` and declaring
the old `GIT_OBJ_` values as a signed or unsigned int, we risk a
mismatch between what the compiler has chosen for a `git_object_t`'s
type and our type declaration.
Thus, we declare the deprecated values as the enum instead of guessing.
|
|
44827b67
|
2019-01-20T10:36:41
|
|
deprecation: add `used` attribute
Recent GCC enables `-Wunused-const-variables`, which makes output quite
noisy. Disable unused warnings for our deprecated variables.
|
|
1758636b
|
2019-01-19T01:38:34
|
|
Merge pull request #4939 from libgit2/ethomson/git_ref
Move `git_ref_t` to `git_reference_t`
|
|
b2c2dc64
|
2019-01-19T01:36:40
|
|
Merge pull request #4940 from libgit2/ethomson/git_obj
More `git_obj` to `git_object` updates
|
|
22d2062d
|
2019-01-09T18:25:10
|
|
Introduce GIT_CALLBACK macro to enforce cdecl
Since we now always build the library with cdecl calling conventions,
our callbacks should be decorated as such so that users will not be able
to provide callbacks defined with other calling conventions.
The `GIT_CALLBACK` macro will inject the `__cdecl` attribute as
appropriate.
|
|
a74dd39b
|
2019-01-09T12:33:47
|
|
Use cdecl calling conventions on Win32
The recommendation from engineers within Microsoft is that libraries
should have a calling convention specified in the public API, and that
calling convention should be cdecl unless there are strong reasons to
use a different calling convention.
We previously offered end-users the choice between cdecl and stdcall
calling conventions. We did this for presumed wider compatibility: most
Windows applications will use cdecl, but C# and PInvoke default to
stdcall for WINAPI compatibility. (On Windows, the standard library
functions are are stdcall so PInvoke also defaults to stdcall.)
However, C# and PInvoke can easily call cdecl APIs by specifying an
annotation.
Thus, we will explicitly declare ourselves cdecl and remove the option
to build as stdcall.
|
|
b78bcbb9
|
2019-01-09T13:21:23
|
|
buffer: wrap EXTERN in DEPRECATED
The GIT_EXTERN macro needs to provide order-specific attributes; update
users of the GIT_DEPRECATED macro to allow for that.
|
|
cd350852
|
2019-01-17T10:40:13
|
|
object_type: GIT_OBJECT_BAD is now GIT_OBJECT_INVALID
We use the term "invalid" to refer to bad or malformed data, eg
`GIT_REF_INVALID` and `GIT_EINVALIDSPEC`. Since we're changing the
names of the `git_object_t`s in this release, update it to be
`GIT_OBJECT_INVALID` instead of `BAD`.
|
|
90046899
|
2019-01-17T10:42:51
|
|
object_type: mark old values as deprecated
Mark old object type values as `static const` so that we can mark them
as deprecated with the `GIT_DEPRECATED` macro.
|
|
87fe5788
|
2019-01-16T23:58:09
|
|
references: use full name in type names
Update the reference type names from an abbreviation (`git_ref`) to use
the fullname (`git_reference`). This ensures that we are consistent
with our naming for reference types and functions throughout the
library.
The previous names are now marked as deprecated.
|
|
5bd78c48
|
2018-12-14T14:41:17
|
|
refs: constify git_reference_peel
We have no need to take a non-const reference. This does involve some other work
to make sure we don't mix const and non-const variables, but by splitting what
we want each variable to do we can also simplify the logic for when we do want
to free a new reference we might have allocated.
|
|
19faf7c5
|
2018-11-14T23:35:48
|
|
object_type: update public API to use git_object_t
git_object_t is the future; update the public API to use it. This will
also ensure that we can build our tests which make use of the old API
without modification (and without compiler warnings).
|
|
26b21b39
|
2018-11-14T22:48:10
|
|
object_type: remove unused object type flags
The two "reserved" bits in `git_object_t` are unused. They were
included for completeness, but downstream users should never use them
and they should not have been made public.
These values are never set.
With the refactoring of `git_otype` into `git_object_t`, we can remove
these from the new API. They will remain in the old (deprecated) API
in the unlikely event that someone was using them.
|
|
7e7859a1
|
2018-11-14T21:12:55
|
|
object_type: update enumeration names
Update the `git_otype` names to reflect our current naming conventions.
`git_otype` is now `git_object_t` and the `GIT_OBJ_*` values are now
`GIT_OBJECT_*` values.
The old macro, enumeration and structure names are retained and simply
set to the new names.
|
|
4e892ae5
|
2018-11-14T21:00:25
|
|
index: update enum and structure names
We have various macro, enumeration and structure names that were
introduced (very) early in the project and do not match our current
naming conventions. For instance: `GIT_IDXENTRY...` flags that
correspond to a structure named `git_index_entry`.
Update these to match the current guidance. The old macros and
enumeration names are reflected as new macros in order to support
backward compatibility (and do so without warnings for consumers).
|
|
0ddc6094
|
2018-11-30T09:46:14
|
|
Merge pull request #4770 from tiennou/feature/merge-analysis-any-branch
Allow merge analysis against any reference
|
|
e7873eb2
|
2018-11-29T08:00:31
|
|
Merge pull request #4888 from TheBB/add-cb
revwalk: Allow changing hide_cb
|
|
02bb39f4
|
2018-11-22T08:49:09
|
|
stream registration: take an enum type
Accept an enum (`git_stream_t`) during custom stream registration that
indicates whether the registration structure should be used for standard
(non-TLS) streams or TLS streams.
|
|
df2cc108
|
2018-11-18T10:29:07
|
|
stream: provide generic registration API
Update the new stream registration API to be `git_stream_register`
which takes a registration structure and a TLS boolean. This allows
callers to register non-TLS streams as well as TLS streams.
Provide `git_stream_register_tls` that takes just the init callback for
backward compatibliity.
|
|
43b592ac
|
2018-10-25T08:49:01
|
|
tls: introduce a wrap function
Introduce `git_tls_stream_wrap` which will take an existing `stream`
with an already connected socket and begin speaking TLS on top of it.
This is useful if you've built a connection to a proxy server and you
wish to begin CONNECT over it to tunnel a TLS connection.
Also update the pluggable TLS stream layer so that it can accept a
registration structure that provides an `init` and `wrap` function,
instead of a single initialization function.
|
|
0836f069
|
2018-11-14T16:08:30
|
|
revwalk: Allow changing hide_cb
Since git_revwalk objects are encouraged to be reused, a public
interface for changing hide_cb is desirable.
|
|
c97d302d
|
2018-11-28T13:45:41
|
|
Merge pull request #4879 from libgit2/ethomson/defer_cert_cred_cb
Allow certificate and credential callbacks to decline to act
|
|
a2e6e0ea
|
2018-11-06T14:15:43
|
|
transport: allow cred/cert callbacks to return GIT_PASSTHROUGH
Allow credential and certificate checking callbacks to return
GIT_PASSTHROUGH, indicating that they do not want to act.
Introduce this to support in both the http and ssh callbacks.
Additionally, enable the same mechanism for certificate validation.
This is most useful to disambiguate any meaning in the publicly exposed
credential and certificate functions (`git_transport_smart_credentials`
and `git_transport_smart_certificate_check`) but it may be more
generally useful for callers to be able to defer back to libgit2.
|
|
0e3e832d
|
2018-11-21T13:30:01
|
|
Merge pull request #4884 from libgit2/ethomson/index_iterator
index: introduce git_index_iterator
|
|
4dcd4514
|
2018-11-18T18:13:58
|
|
worktree: Expose git_worktree_add_init_options
|
|
8ee10098
|
2018-11-06T13:10:30
|
|
transport: see if cert/cred callbacks exist before calling them
Custom transports may want to ask libgit2 to invoke a configured
credential or certificate callback; however they likely do not know if a
callback was actually configured. Return a sentinal value
(GIT_PASSTHROUGH) if there is no callback configured instead of crashing.
|
|
c358bbc5
|
2018-11-12T17:22:47
|
|
index: introduce git_index_iterator
Provide a public git_index_iterator API that is backed by an index
snapshot. This allows consumers to provide a stable iteration even
while manipulating the index during iteration.
|
|
20cb30b6
|
2018-11-13T13:40:17
|
|
Merge pull request #4667 from tiennou/feature/remote-create-api
Remote creation API
|
|
47cc5f85
|
2018-09-29T19:32:51
|
|
apply: introduce a hunk callback
Introduce a callback to patch application that allows consumers to
cancel hunk application.
|
|
af33210b
|
2018-07-10T16:10:03
|
|
apply: introduce a delta callback
Introduce a callback to the application options that allow callers to
add a per-delta callback. The callback can return an error code to stop
patch application, or can return a value to skip the application of a
particular delta.
|
|
37b25ac5
|
2018-07-08T16:12:58
|
|
apply: move location to an argument, not the opts
Move the location option to an argument, out of the options structure.
This allows the options structure to be re-used for functions that don't
need to know the location, since it's implicit in their functionality.
For example, `git_apply_tree` should not take a location, but is
expected to take all the other options.
|
|
c3077ea0
|
2018-06-25T21:24:49
|
|
apply: return a specific exit code on failure
Return `GIT_EAPPLYFAIL` on patch application failure so that users can
determine that patch application failed due to a malformed/conflicting
patch by looking at the error code.
|
|
f83bbe0a
|
2018-03-19T19:50:45
|
|
apply: introduce `git_apply`
Introduce `git_apply`, which will take a `git_diff` and apply it to the
working directory (akin to `git apply`), the index (akin to `git apply
--cached`), or both (akin to `git apply --index`).
|
|
02b1083a
|
2018-01-28T23:25:07
|
|
apply: introduce `git_apply_tree`
Introduce `git_apply_tree`, which will apply a `git_diff` to a given
`git_tree`, allowing an in-memory patch application for a repository.
|
|
d3650294
|
2018-06-20T02:27:14
|
|
remote: add a flag to prevent generation of the default fetchspec
|
|
fdb116b3
|
2018-06-20T02:27:12
|
|
remote: add a creation flag for ignoring url.insteadOf
|
|
3cbaebdf
|
2018-06-20T02:27:11
|
|
remote: provide a generic API for creating remotes
This supersedes the functionality of remote_create_with_fetchspec, remote_create_anonymous and remote_create_detached.
|
|
305e801a
|
2018-10-21T09:52:32
|
|
util: allow callers to reset custom allocators
Provide a utility to reset custom allocators back to their default.
This is particularly useful for testing.
|
|
6e9fb040
|
2018-08-25T01:47:39
|
|
merge: make analysis possible against a non-HEAD reference
This moves the current merge analysis code into a more generic version
that can work against any reference.
Also change the tests to check returned analysis values exactly.
|
|
05e54e00
|
2018-10-15T13:54:17
|
|
path: export the dotgit-checking functions
These checks are preformed by libgit2 on checkout, but they're also useful for
performing checks in applications which do not involve checkout.
Expose them under `sys/` as it's still fairly in the weeds even for this
library.
|
|
25da1acb
|
2018-09-25T14:43:19
|
|
config: fix incorrect filename in documentation comment
The underlying code uses GIT_CONFIG_FILENAME_GLOBAL, which is .gitconfig.
|
|
7283daa8
|
2018-10-01T21:00:15
|
|
doc: small fixups & additions
|
|
330b10ca
|
2018-09-17T21:53:58
|
|
revwalk: refer the sorting modes more to git's options
Show more directly what the sorting modes correspond to in git's `rev-list` as
that's the reference implementation for what the possible sorting orders are.
|
|
7edc1c87
|
2018-08-30T12:51:05
|
|
Merge pull request #4788 from tiennou/doc-fixes
Documentation fixes
|
|
db0c6648
|
2018-08-30T12:22:26
|
|
Merge pull request #4773 from RandomSort/giterr
Document giterr_last() use only after error. #4772
|
|
a4a028be
|
2018-08-29T22:49:35
|
|
diff: documentation mashup
|
|
9890f059
|
2018-08-29T22:04:42
|
|
push: make the parallelism default follow the docs
|
|
7765c0a9
|
2018-08-29T21:56:26
|
|
doc: fix comment on GIT_EUSER
|
|
c0b2e525
|
2018-08-27T09:23:02
|
|
Add two words to clarify
|
|
50186ce8
|
2018-08-26T11:26:45
|
|
Merge pull request #4374 from pks-t/pks/pack-file-verify
Pack file verification
|
|
4bd2a508
|
2018-08-20T13:51:28
|
|
Update giterr_last API documentation to reflect real behaviour
|
|
42f83840
|
2018-07-26T15:25:44
|
|
Merge pull request #4721 from nelhage/max-objects
Add a configurable limit to the max pack size that will be indexed
|
|
ea9e2c1a
|
2018-07-20T13:06:56
|
|
Merge pull request #4692 from tiennou/examples/checkout
Add a checkout example
|
|
b3ca817e
|
2018-07-16T03:14:33
|
|
INDEXER_MAX_OBJECTS -> PACK_MAX_OBJECTS
|
|
9cab93c0
|
2018-07-13T21:29:01
|
|
ignore: improve `git_ignore_path_is_ignored` description Git analogy
In attempt to provide adequate Git command analogy in regards to
ignored files handling, `git_ignore_path_is_ignored` description
mentions doing `git add .` on directory containing the file, and
whether the file in question would be added or not - but behavior of
the two matches for untracked files only, making the comparison
misleading in general sense.
For tracked files, Git doesn't subject them to ignore rules, so even
if a rule applies, `git add .` would actually add the tracked file
changes to index, while `git_ignore_path_is_ignored` would still
consider the file being ignored (as it doesn't check the index, as
documented).
Let's provide `git check-ignore --no-index` as analogous Git command
example instead, being more aligned with what `git_ignore_path_is_ignored`
is about, no matter if the file in question is already tracked or not.
See issue #4720 (git_ignore_path_is_ignored documentation
misleading?, 2018-07-10)[1] for additional information.
[1] https://github.com/libgit2/libgit2/issues/4720
|
|
efe3f37d
|
2018-07-12T04:20:15
|
|
Add a git_libgit2_opts option to set the max indexer object count
|
|
698b4463
|
2018-06-23T13:06:10
|
|
annotated_commit: make the refname accessible
As git_annotated_commit seems to behave like cgit's refish, it's quite
helpful to abstract away "targets" via git_annotated_commit_from_id/from_ref.
As the former is accessible via git_annotated_commit_id, make the latter
also available to users.
|
|
c43658f6
|
2018-06-30T13:24:23
|
|
Merge pull request #4536 from libgit2/ethomson/index_dirty
Add a "dirty" state to the index when it has unsaved changes
|
|
bfa1f022
|
2018-06-22T19:17:08
|
|
settings: optional unsaved index safety
Add the `GIT_OPT_ENABLE_UNSAVED_INDEX_SAFETY` option, which will cause
commands that reload the on-disk index to fail if the current
`git_index` has changed that have not been saved. This will prevent
users from - for example - adding a file to the index then calling a
function like `git_checkout` and having that file be silently removed
from the index since it was re-read from disk.
Now calls that would re-read the index will fail if the index is
"dirty", meaning changes have been made to it but have not been written.
Users can either `git_index_read` to discard those changes explicitly,
or `git_index_write` to write them.
|
|
787768c2
|
2018-06-22T19:07:54
|
|
index: return a unique error code on dirty index
When the index is dirty, return GIT_EINDEXDIRTY so that consumers can
identify the exact problem programatically.
|
|
630a6736
|
2018-02-07T22:30:27
|
|
refspec: add public parsing api
Fix typo
Fix some type issues
More fixes
Address requested changes
Add test
Fix naming
Fix condition and tests
Address requested changes
Fix typo
|
|
5ec4aee9
|
2017-11-12T10:35:18
|
|
indexer: add ability to select connectivity checks
Right now, we simply turn on connectivity checks in the indexer as soon
as we have access to an object database. But seeing that the
connectivity checks may incur additional overhead, we do want the user
to decide for himself whether he wants to allow those checks.
Furthermore, it might also be desirable to check connectivity in case
where no object database is given at all, e.g. in case where a fully
connected pack file is expected.
Add a flag `verify` to `git_indexer_options` to enable additional
verification checks. Also avoid to query the ODB in case none is given
to allow users to enable checks when they do not have an ODB.
|
|
c16556aa
|
2017-11-12T10:31:48
|
|
indexer: introduce options struct to `git_indexer_new`
We strive to keep an options structure to many functions to be able to
extend options in the future without breaking the API. `git_indexer_new`
doesn't have one right now, but we want to be able to add an option
for enabling strict packfile verification.
Add a new `git_indexer_options` structure and adjust callers to use
that.
|
|
b5818dda
|
2018-06-18T13:05:08
|
|
Fix last references to deprecated git_buf_free
Signed-off-by: Sven Strickroth <email@cs-ware.de>
|
|
f98131be
|
2018-06-17T00:40:25
|
|
Require the length argument to git_mailmap_from_buffer and make mailmap_add_buffer internal
|
|
d91d2968
|
2018-06-14T16:49:48
|
|
mailmap: Hide EEXISTS to simplify git_mailmap_add_entry callers
|
|
56303e1a
|
2018-05-07T11:59:00
|
|
mailmap: API and style cleanup
|
|
8ff0504d
|
2018-04-08T03:01:14
|
|
mailmap: Rewrite API to support accurate mailmap resolution
|
|
18ff9bab
|
2018-03-27T22:48:03
|
|
mailmap: API and style cleanup
|
|
57cfeab9
|
2018-03-26T15:05:37
|
|
mailmap: Switch mailmap parsing to use the git_parse module
|
|
5c6c8a9b
|
2018-03-18T01:26:30
|
|
mailmap: Fix some other minor style nits
|
|
4ff44be8
|
2018-03-17T18:24:15
|
|
mailmap: Fix more bugs which snuck in when I rebased
|
|
e3dcaca5
|
2018-03-17T18:15:01
|
|
mailmap: Integrate mailmaps with blame and signatures
|
|
b05fbba3
|
2018-03-17T18:14:31
|
|
mailmap: Make everything a bit more style conforming
|