public static String getFileDir(String filePath) {
    int lastSlash = filePath.lastIndexOf('/');
    return filePath.substring(0, lastSlash);
  }
Parse file directory path from file path

@param filePath file path
@return file directory path parsed from file path
amoro-format-iceberg/src/main/java/org/apache/amoro/utils/TableFileUtil.java