code: static String escapePath(String input) {
      // Handle special characters
      String encodedInput = input.replace(':', '-')
          .replace('\\', '/')
          .replace(" ", "%20")
          .replace("[", "%5B")
          .replace("]", "%5D")
          .replace("<", "%3C")
          .replace(">", "%3E");
  
      return canonicalizePath(encodedInput);
    }
docs: Escapes the given input path.