@RequiresEdt
  public static boolean makeWritable(@Nullable Project project, @NotNull VirtualFile file) {
    if (project == null) project = ProjectManager.getInstance().getDefaultProject();
    return !ReadonlyStatusHandler.getInstance(project).ensureFilesWritable(Collections.singletonList(file)).hasReadonlyFiles();
  }
@RequiresEdt
  public static boolean makeWritable(@Nullable Project project, @NotNull VirtualFile file)