You signed in with another tab or window.Reload to refresh your session.You signed out in another tab or window.Reload to refresh your session.You switched accounts on another tab or window.Reload to refresh your session.Dismiss alert
This is release v1.9.0, "Schwibbogen". As usual, it contains numerous bug fixes, compatibility improvements, and new features.
This is expected to be the final release in the libgit2 v1.x lineage. libgit2 v2.0 is expected to be the next version, with support for SHA256 moving to "supported" status (out of "experimental" status). This means that v2.0 will have API and ABI changes to support SHA256, as well as otherbreaking changes.
Major changes
Documentation improvements We've launched a new website for our API reference docs athttps://libgit2.org/docs/reference/main. To support this, we've updated the documentation to ensure that all APIs are well-documented, and added docurium-style specifiers to indicate more depth about the API surface.
We now also publish a JSON blob with the API structure and the documentation that may be helpful for binding authors.
TLS cipher updates libgit2 has updated our TLS cipher selection to match the "compatibility" cipher suite settings asdocumented by Mozilla.
Blame improvements The blame API now contains committer information and commit summaries for blame hunks, and the ability to get information about the line of text that was modified. In addition, a CLI blame command has been added so that the blame functionality can be benchmarked by our benchmark suite.
More CLI commands libgit2 has addedblame andinit commands, which have allowed forfurther benchmarking and several API improvements and git compatibility updates.
Warning when configuring without SHA1DC Users are encouraged to use SHA1DC, which isgit's hash;users should not use SHA1 in the general case. Users will now be warned if they try to configure cmake with a SHA1 backend (-DUSE_SHA1=...).
Breaking changes
There are several ABI-breaking changes that integrators, particularly maintainers of bindings or FFI users, may want to be aware of.
Blame hunk structure updates (ABI breaking change) There are numerous additions to thegit_blame_hunk structure to accommodate more information about the blame process.
Checkout strategy updates (ABI breaking change) The values forGIT_CHECKOUT_SAFE andGIT_CHECKOUT_NONE have been updated.GIT_CHECKOUT_SAFE is now0; this was implicitly the default value (with the options constructors setting that as the checkout strategy). It is now the default if the checkout strategy is set to0. This allows for an overall code simplification in the library.
Configuration entry member removal (ABI breaking change) Thegit_config_entry structure no longer contains afree member; this was an oversight as end-users should not try to free that structure.
Configuration backend function changes (ABI breaking change) git_config_backends should now returngit_config_backend_entry objects instead ofgit_config_entry objects. This allows backends to provide a mechanism to nicely free the configuration entries that they provide.
update_refs callback for remotes (ABI breaking change) Theupdate_refs callback was added to thegit_remote_callbacks structure to provide additional information about updated refs; in particular, thegit_refspec is included for more information about the remote ref. Theupdate_refs callback will be preferred over the now deprecatedupdate_tips callback.
What's Changed
New features
Thegit_signature_default_from_env API will now produce a pair ofgit_signatures representing the author, and the committer, taking theGIT_AUTHOR_NAME andGIT_COMMITTER_NAME environment variables into account. Added by@u-quark inUse environment variables when creating signatures #6706
libgit2 now claims to honor thepreciousObject repository extension. This extension indicates that the client will never delete objects (in other words, will not garbage collect). libgit2 has no functionality to remove objects, so it implicitly obeys this in all cases. Added by@ethomson inrepo: support the preciousObjects extension #6886
The newLIBGIT2_VERSION_CHECK macro will indicate whether the version of libgit2 being compiled against is at least the version specified. For example:#if LIBGIT2_VERSION_CHECK(1, 6, 3) is true for libgit2 version 1.6.3 or newer. In addition, the newLIBGIT2_VERSION_NUMBER macro will return an integer version representing the libgit2 version number. For example, for version 1.6.3,LIBGIT2_VERSION_NUMBER will evaluate to010603. Added by@HamedMasafi inAdd LIBGIT2_VER_CHECK Macro for Version Comparison #6882
Remote callbacks now provide anupdate_refs callback so that users can now get therefspec of the updated reference during push. This gives more complete information about the remote reference that was updated. Added by@ethomson inremote: add update_refs with git_refspec #6559
The git-compatible CLI now supports thegit init command, which has been useful in identifying API improvements and incompatibilities with git. Added by@ethomson inCLI: introduceinit command #6984
I think also the layout ofgit_remote_callbacks changed in#6559? I don't see it mentioned among the breaking changes. Reported atJuliaLang/julia#56955 (comment)Edit: ah, it's mentioned in the non-breaking changes.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji