Browse Source

DirCacheCheckout: don't use deprecated method

Pass the CheckoutMetadata to checkoutEntry(), otherwise cr-lf settings
and smudge filters would be ignored.

Change-Id: Ifb1c4cb098a0b47c9752d0231d530db6a92b25a4
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
next
Thomas Wolf 5 years ago
parent
commit
e8c3619063
  1. 7
      org.eclipse.jgit/src/org/eclipse/jgit/dircache/DirCacheCheckout.java

7
org.eclipse.jgit/src/org/eclipse/jgit/dircache/DirCacheCheckout.java vendored

@ -1243,9 +1243,12 @@ public class DirCacheCheckout {
if (e != null && !FileMode.TREE.equals(e.getFileMode()))
builder.add(e);
if (force) {
if (f.isModified(e, true, this.walk.getObjectReader())) {
if (f.isModified(e, true, walk.getObjectReader())) {
kept.add(path);
checkoutEntry(repo, e, this.walk.getObjectReader());
checkoutEntry(repo, e, walk.getObjectReader(), false,
new CheckoutMetadata(walk.getEolStreamType(CHECKOUT_OP),
walk.getFilterCommand(
Constants.ATTR_FILTER_TYPE_SMUDGE)));
}
}
}

Loading…
Cancel
Save