private static Promise<ProjectTaskManager.Result> recompileFiles(List<String> fileNames, Project project) {
    var files = fileNames.stream().map(fileName -> {
      var file = OpenFileCommand.findFile(fileName, project);
      if (file == null) throw new IllegalStateException("File not found : " + fileName);
      return file;
    }).toArray(VirtualFile[]::new);

    if (files.length == 0) {
      throw new IllegalStateException("Enter at least one file");
    }

    return ProjectTaskManager.getInstance(project).compile(files);
  }
private static Promise<ProjectTaskManager.Result> recompileFiles(List<String> fileNames, Project project)