Community
Participate
Working Groups
The git native protocol supports shallow clones. JGit's implementation of that protocol on the server side should support servicing clients that are using the shallow clone feature.
*** Bug 332988 has been marked as a duplicate of this bug. ***
We have some code here: http://egit.eclipse.org/r/#change,1320
(In reply to comment #2) > We have some code here: > > http://egit.eclipse.org/r/#change,1320 That's not enough. We also have to fix RevWalk to understand the shallow boundary and avoid trying to walk beyond it.
I have someone working on this, and may have updated patches soon.
Change 1320 on egit.eclipse.org has been updated and filed as CQ 5517.
We're going to have to get Matt Fischer to reaffirm his contribution on this bug according to the Eclipse IP process.
Can we have Mat confirm: 1. You have authored 100% of the content contained within the patch. 2. You have the rights to contribute the content to the JGit project. 3. You agree you are contributing the content under the EDL, which is the BSD license appearing in our file headers.
I confirm that: 1) I am the sole author of this commit 2) I have the rights to contribute this code to JGit 3) I am submitting this change to the Eclipse project under the terms of the EDL
Matt, can you answer this question from the Eclipse IP team? > Would you happen to know why it appears copyright belongs to > both employer and employee?
I'm not exactly sure what they're asking...is it because my comment said that I held the rights to contribute the commit, and then we also had an employer verification that said they owned the rights? If so, I guess I misunderstood what I needed to say in my individual statement. This code was written by me (Matt Fischer) on behalf of my employer (Garmin International). I've given an individual consent as a comment in this thread, and my employer has given a consent in response to an email we received from Sharon Corbett asking for employer consent. So regardless of whether the copyright is seen as held by me or my employer, I believe that we've given consent to contribute the code to Eclipse. In any case, that's been the intent--is there something else we need to do?
Thanks for your patience Matt, look forward to more patches now since you're IP cleared :D
This ticket was closed quite a while back as fixed, but I can't find any references in JGit docs or API on how to use it. Can anyone confirm if the ability to do a shallow clone was actually added to JGit and if it is documented anywhere?
This bug was about the server implementation inside of JGit. The server now supports shallow fetch/clone automatically if the client requests it. AFAIK the JGit client does not yet support shallow fetch or clone. Adding that support should be under a different bug.
Thanks for explaining Shawn. I had come across several places on the internet that linked to this bug thinking it affected the client. I have entered this bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=475615
Pushing to a new JGit-hosted repo from shallow clone seems still doesn't work. Tried to push to Gerrit 3.0.1 repo: $ git push Counting objects: 4, done. Delta compression using up to 2 threads. Compressing objects: 100% (2/2), done. Writing objects: 100% (4/4), 325 bytes | 325.00 KiB/s, done. Total 4 (delta 1), reused 2 (delta 0) remote: Resolving deltas: 100% (1/1) error: remote unpack failed: error Missing commit b498feadb1c3a0d7904d316ef923516b0f16a95c To https://gerrit/a/test ! [remote rejected] master -> master (n/a (unpacker error)) error: failed to push some refs
(In reply to Andrey Butirsky from comment #15) > Pushing to a new JGit-hosted repo from shallow clone seems still doesn't > work. Maybe related: [PATCH] Missing commit when fetching on shallow clone https://bugs.eclipse.org/bugs/show_bug.cgi?id=455343