/** * Remembers the {@link CheckoutMetadata} for the given path; it may be * needed in {@link #checkout()} or in {@link #cleanUp()}. * * @param path * of the current node * @param attributes * for the current node * @throws IOException * if the smudge filter cannot be determined * @since 5.1 */ protected void addCheckoutMetadata(String path, Attributes attributes) throws IOException { if (checkoutMetadata != null) { EolStreamType eol = EolStreamTypeUtil.detectStreamType( OperationType.CHECKOUT_OP, workingTreeOptions, attributes); CheckoutMetadata data = new CheckoutMetadata(eol, tw.getFilterCommand(Constants.ATTR_FILTER_TYPE_SMUDGE)); checkoutMetadata.put(path, data); } }
new CheckoutMetadata(eolStreamType, null)); actuallyModifiedPaths.add(entry.getPathString());
new CheckoutMetadata(eolStreamType, null));
@Override public void apply(DirCacheEntry ent) { int stage = ent.getStage(); if (stage > DirCacheEntry.STAGE_0) { if (checkoutStage != null) { if (stage == checkoutStage.number) { checkoutPath(ent, r, new CheckoutMetadata( eolStreamType, filterCommand)); actuallyModifiedPaths.add(path); } } else { UnmergedPathException e = new UnmergedPathException( ent); throw new JGitInternalException(e.getMessage(), e); } } else { checkoutPath(ent, r, new CheckoutMetadata(eolStreamType, filterCommand)); actuallyModifiedPaths.add(path); } } });
/** * Remembers the {@link CheckoutMetadata} for the given path; it may be * needed in {@link #checkout()} or in {@link #cleanUp()}. * * @param path * of the current node * @param attributes * for the current node * @throws IOException * if the smudge filter cannot be determined * @since 5.1 */ protected void addCheckoutMetadata(String path, Attributes attributes) throws IOException { if (checkoutMetadata != null) { EolStreamType eol = EolStreamTypeUtil.detectStreamType( OperationType.CHECKOUT_OP, workingTreeOptions, attributes); CheckoutMetadata data = new CheckoutMetadata(eol, tw.getFilterCommand(Constants.ATTR_FILTER_TYPE_SMUDGE)); checkoutMetadata.put(path, data); } }
public void apply(DirCacheEntry ent) { int stage = ent.getStage(); if (stage > DirCacheEntry.STAGE_0) { if (checkoutStage != null) { if (stage == checkoutStage.number) checkoutPath(ent, r, new CheckoutMetadata( eolStreamType, filterCommand)); } else { UnmergedPathException e = new UnmergedPathException( ent); throw new JGitInternalException(e.getMessage(), e); } } else { checkoutPath(ent, r, new CheckoutMetadata(eolStreamType, filterCommand)); } } });
@Override public void apply(DirCacheEntry ent) { ent.setObjectId(blobId); ent.setFileMode(mode); checkoutPath(ent, r, new CheckoutMetadata(eolStreamType, filterCommand)); actuallyModifiedPaths.add(path); } });
private void update(String path, ObjectId mId, FileMode mode) throws IOException { if (!FileMode.TREE.equals(mode)) { updated.put(path, new CheckoutMetadata( walk.getEolStreamType(CHECKOUT_OP), walk.getFilterCommand(Constants.ATTR_FILTER_TYPE_SMUDGE))); DirCacheEntry entry = new DirCacheEntry(path, DirCacheEntry.STAGE_0); entry.setObjectId(mId); entry.setFileMode(mode); builder.add(entry); } }
private void update(String path, ObjectId mId, FileMode mode) throws IOException { if (!FileMode.TREE.equals(mode)) { updated.put(path, new CheckoutMetadata(walk.getEolStreamType(), walk.getFilterCommand(Constants.ATTR_FILTER_TYPE_SMUDGE))); DirCacheEntry entry = new DirCacheEntry(path, DirCacheEntry.STAGE_0); entry.setObjectId(mId); entry.setFileMode(mode); builder.add(entry); } }
public void apply(DirCacheEntry ent) { ent.setObjectId(blobId); ent.setFileMode(mode); checkoutPath(ent, r, new CheckoutMetadata(eolStreamType, filterCommand)); } });
new CheckoutMetadata(eolStreamType, null)); actuallyModifiedPaths.add(entry.getPathString());
@Override public void apply(DirCacheEntry ent) { int stage = ent.getStage(); if (stage > DirCacheEntry.STAGE_0) { if (checkoutStage != null) { if (stage == checkoutStage.number) { checkoutPath(ent, r, new CheckoutMetadata( eolStreamType, filterCommand)); actuallyModifiedPaths.add(path); } } else { UnmergedPathException e = new UnmergedPathException( ent); throw new JGitInternalException(e.getMessage(), e); } } else { checkoutPath(ent, r, new CheckoutMetadata(eolStreamType, filterCommand)); actuallyModifiedPaths.add(path); } } });
private void update(String path, ObjectId mId, FileMode mode) throws IOException { if (!FileMode.TREE.equals(mode)) { updated.put(path, new CheckoutMetadata( walk.getEolStreamType(CHECKOUT_OP), walk.getFilterCommand(Constants.ATTR_FILTER_TYPE_SMUDGE))); DirCacheEntry entry = new DirCacheEntry(path, DirCacheEntry.STAGE_0); entry.setObjectId(mId); entry.setFileMode(mode); builder.add(entry); } }
@Override public void apply(DirCacheEntry ent) { ent.setObjectId(blobId); ent.setFileMode(mode); checkoutPath(ent, r, new CheckoutMetadata(eolStreamType, filterCommand)); actuallyModifiedPaths.add(path); } });