Browse Source

Ignore submodule commits during checkout

Submodules are supposed to be handled by separate operations, so
we should ignore them on checkout, just like C Git does.

This fix does not add submodule support. We just try harder
to ignore them.

Bug: 343566
Change-Id: I2c5ae1024ea7bb57adf27072da6acc9643018eda
Signed-off-by: Robin Rosenberg <robin.rosenberg@dewire.com>
tags/v1.0.0.201106011211-rc3
Robin Rosenberg 13 years ago
parent
commit
5f22d67270

+ 6
- 0
org.eclipse.jgit/src/org/eclipse/jgit/dircache/DirCacheCheckout.java View File

@@ -417,7 +417,13 @@ public class DirCacheCheckout {
if (!file.getParentFile().mkdirs()) {
// ignore
}

DirCacheEntry entry = dc.getEntry(path);

// submodules are handled with separate operations
if (FileMode.GITLINK.equals(entry.getRawMode()))
continue;

checkoutEntry(repo, file, entry);
}


Loading…
Cancel
Save