public static void copy(Path src, Path dst, boolean overwrite) throws IOException {
    LOG.info(src + (overwrite ? " over " : " into ") + dst);

    var attrs = Files.readAttributes(src, BasicFileAttributes.class, LinkOption.NOFOLLOW_LINKS);
    if (attrs.isDirectory()) {
      Files.createDirectories(dst);
    }
    else if (WIN_UNPRIVILEGED && attrs.isSymbolicLink()) {
      if (overwrite) Files.deleteIfExists(dst);
      Files.createDirectories(dst.getParent());
      Files.createSymbolicLink(dst, Files.readSymbolicLink(src));
    }
    else {
      Files.createDirectories(dst.getParent());
      Files.copy(src, dst, overwrite ? COPY_REPLACE : COPY_STANDARD);
    }
  }
public static void copy(Path src, Path dst, boolean overwrite)