public static void acceptOneVersion(@NotNull Project project,
                                      @NotNull VirtualFile root,
                                      @NotNull Collection<? extends GitConflict> conflicts,
                                      @NotNull GitConflict.ConflictSide side) throws VcsException {
    boolean isCurrent = side == GitConflict.ConflictSide.OURS;

    for (GitConflict conflict : conflicts) {
      assert root.equals(conflict.getRoot());
    }

    List<FilePath> toCheckout = new ArrayList<>();

    for (GitConflict conflict : conflicts) {
      GitConflict.Status status = conflict.getStatus(side);
      FilePath filePath = conflict.getFilePath();

      if (status != GitConflict.Status.DELETED) {
        toCheckout.add(filePath);
      }
    }

    for (List<String> paths : VcsFileUtil.chunkPaths(root, toCheckout)) {
      GitLineHandler handler = new GitLineHandler(project, root, GitCommand.CHECKOUT);
      handler.addParameters(isCurrent ? "--ours" : "--theirs");
      handler.endOptions();
      handler.addParameters(paths);

      Git.getInstance().runCommand(handler).throwOnError();
    }
  }
public static void acceptOneVersion(@NotNull Project project,
                                      @NotNull VirtualFile root,
                                      @NotNull Collection<? extends GitConflict> conflicts,
                                      @NotNull GitConflict.ConflictSide side)