@NotNull
 private static FilePath rebasePath(
     @NotNull FilePath oldBase, @NotNull FilePath newBase, @NotNull FilePath path) {
   String relativePath =
       ObjectUtils.assertNotNull(FileUtil.getRelativePath(oldBase.getPath(), path.getPath(), '/'));
   return VcsUtil.getFilePath(newBase.getPath() + "/" + relativePath, path.isDirectory());
 }
 private String modifyCheckinActionName(final VcsContext dataContext, String checkinActionName) {
   final FilePath[] roots = getRoots(dataContext);
   if (roots == null || roots.length == 0) return checkinActionName;
   final FilePath first = roots[0];
   if (roots.length == 1) {
     if (first.isDirectory()) {
       return VcsBundle.message("action.name.checkin.directory", checkinActionName);
     } else {
       return VcsBundle.message("action.name.checkin.file", checkinActionName);
     }
   } else {
     if (first.isDirectory()) {
       return VcsBundle.message("action.name.checkin.directories", checkinActionName);
     } else {
       return VcsBundle.message("action.name.checkin.files", checkinActionName);
     }
   }
 }
 private static boolean directoryOrBinary(final Change change) {
   // todo instead for repository tab, filter directories (? ask remotely ? non leaf nodes)
   /*if ((change.getBeforeRevision() instanceof BinaryContentRevision) || (change.getAfterRevision() instanceof BinaryContentRevision)) {
     changesList.remove(i);
     continue;
   }*/
   final FilePath path = ChangesUtil.getFilePath(change);
   if (path.isDirectory()) {
     return !change.hasOtherLayers();
   }
   /*final FileType type = path.getFileType();
   if ((! FileTypes.UNKNOWN.equals(type)) && (type.isBinary())) {
     return true;
   }*/
   return false;
 }