Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

bundle: Add bundle transport and test cloning from a bundle#7101

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Draft
lrm29 wants to merge1 commit intolibgit2:main
base:main
Choose a base branch
Loading
frommathworks:bundle_clone

Conversation

lrm29
Copy link
Contributor

@lrm29lrm29 commentedJun 30, 2025
edited
Loading

Enables cloning and fetching from bundles.

I implemented it as a new "transport", so the entry point is in transport_find_fn, where we check if a local file is a bundle (but only after we have attempted to find other transport options).

The documentation I used to implement this is here:

Git: Bundle File Format Documentation
Git: Bundle Documentation

Still Todo:

  • Enforce the prerequisite commits when present. I think this would be done in bundle_negotiate_fetch.
  • Add a libgit2 API to create bundles.
  • Show progress reading the pack?

Some puzzles:

  • I had to add "sort_head_to_front" as clients of ls_remote such as local clone require HEAD to be the first in the list.
  • read_until_packfile felt a bit dirty/inefficient reading byte-by-byte until the double newline, which denotes the start of the packfile.

Closes#6824 and#1718.

@lrm29lrm29force-pushed thebundle_clone branch 6 times, most recently froma997ee6 to877a3aeCompareJuly 1, 2025 09:57
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

Support for bundle create, fetch, clone
1 participant
@lrm29

[8]ページ先頭

©2009-2025 Movatter.jp