Skip to content

libgit2 v1.8.0

Latest
Compare
Choose a tag to compare
@ethomson ethomson released this 20 Mar 20:54
· 30 commits to main since this release
d74d491

v1.8

This is release v1.8.0, "Das Fliegende Klassenzimmer". This release includes optional, experimental support for invoking OpenSSH to fetch and push, an easier mechanism to perform the default behavior of git commit, and has many improvements for worktrees. This release also includes many other new features and bugfixes.

Major changes

  • Executable SSH (OpenSSH) support
    libgit2 can now invoke the command-line OpenSSH to fetch from and push to remotes over SSH. This support takes the place of libssh2 support. To use it, configure libgit2 with cmake -DUSE_SSH=exec, and please report any problems that you discover. By @ethomson in #6617

  • Simplified commit creation
    The git_commit_create_from_stage API was introduced to allow users to better emulate the behavior of git commit without needing to provide unnecessary information. The current state of the index is committed to the current branch. By @ethomson in #6716

  • Worktree improvements
    A number of worktree improvements have been made for better compatibility with core git. First, libgit2 now understands per-worktree references, thanks to @csware in #6387. Worktree-specific configuration is now supported, thanks to @vermiculus in #6202. And improved compatibility with git worktree add is now supported, thanks to @herrerog in #5319.

Breaking changes

  • Adding WORKTREE configuration level (ABI breaking change)
    To support worktree configurations at the appropriate level (higher priority than local configuration, but lower priority than app-specific configuration), the GIT_CONFIG_LEVEL_WORKTREE level was introduced at priority 6. GIT_CONFIG_LEVEL_APP now begins at priority 7.

  • Changes to git_config_entry (ABI breaking change) The git_config_entry structure now contains information about the backend_type and origin_path. The unused payload value has been removed.

  • git_push_options includes remote push options (ABI breaking change)
    The git_push_options structure now contains a value for remote push options.

Other changes

New features

Bug fixes

  • repository: make cleanup safe for re-use with grafts by @carlosmn in #6600
  • fix: Add missing include for oidarray. by @dvzrv in #6608
  • ssh: fix known_hosts leak in _git_ssh_setup_conn by @steven9724 in #6599
  • proxy: Return an error for invalid proxy URLs instead of crashing. by @lrm29 in #6597
  • errors: refactoring - never return NULL in git_error_last() by @ethomson in #6625
  • Reject potential option injections over ssh by @carlosmn in #6636
  • remote: fix memory leak in git_remote_download() by @7Ji in #6651
  • git2: Fix crash when called w/o parameters by @csware in #6673
  • Avoid macro redefinition of ENABLE_INTSAFE_SIGNED_FUNCTIONS by @csware in #6666
  • util: suppress some uninitialized variable warnings by @boretrk in #6659
  • fetch: enable deepening/shortening shallow clones by @kempniu in #6662
  • push: set generic error in push_negotiation cb by @ethomson in #6675
  • process: test /usr/bin/false on BSDs by @ethomson in #6677
  • clone: don't mix up "http://url" with "http:/url" when figuring out if we should do a local clone by @boretrk in #6361
  • Several compatibility fixes by @ethomson in #6678
  • Git blame buffer gives the wrong result in many cases where there are… by @thosey in #6572
  • Fix 'path cannot exist in repository' during diff for in-memory repository by @kcsaul in #6683
  • process: don't try to close the status by @ethomson in #6693
  • Minor bug fixes by @ethomson in #6695
  • Bypass shallow clone support for in-memory repositories by @kcsaul in #6684
  • examples: use unsigned int for bitfields by @ethomson in #6699
  • Fix some bugs caught by UBscan by @ethomson in #6700
  • git_diff_find_similar doesn't always remove unmodified deltas by @yori in #6642
  • httpclient: clear client->parser.data after use by @ethomson in #6705
  • Do not normalize safe.directory paths by @csware in #6668
  • clone: don't swallow error in should_checkout by @ethomson in #6727
  • Correct index add directory/file conflict detection by @ethomson in #6729
  • Correct git_revparse_single and add revparse fuzzing by @ethomson in #6730
  • config: properly delete or rename section containing multivars by @samueltardieu in #6723
  • revparse: ensure bare '@' is truly bare by @ethomson in #6742
  • repo: ensure we can initialize win32 paths by @ethomson in #6743
  • Swap GIT_DIFF_LINE_(ADD|DEL)_EOFNL to match other Diffs by @xphoniex in #6240
  • diff: fix test for SHA256 support in diff_from_buffer by @ethomson in #6745
  • http: support empty http.proxy config setting by @ethomson in #6744
  • More safe.directory improvements by @ethomson in #6739
  • Ensure that completely ignored diff is empty by @ethomson in #5893
  • Fix broken regexp that matches submodule names containing ".path" by @csware in #6749
  • Fix memory leaks by @csware in #6748
  • Make refdb_fs (hopefully) fully aware of per worktree refs by @csware in #6387
  • fix log example by @albfan in #6359
  • fetch: fail on depth for local transport by @ethomson in #6757
  • Fix message trailer parsing by @ethomson in #6761
  • config: correct fetching the HIGHEST_LEVEL config by @ethomson in #6766
  • Avoid some API breaking changes in v1.8 by @ethomson in #6768

Build and CI improvements

Documentation improvements

Platform compatibility fixes

  • stransport: macOS: replace errSSLNetworkTimeout, with hard-coded value by @mascguy in #6610

Git compatibility fixes

Dependency updates

New Contributors

Full Changelog: v1.7.0...v1.8.0