public static @Nullable GitRepository guessWidgetRepository(@NotNull Project project, @Nullable VirtualFile selectedFile) {
    GitVcsSettings settings = GitVcsSettings.getInstance(project);
    return DvcsUtil.guessWidgetRepository(project, GitUtil.getRepositoryManager(project), settings.getRecentRootPath(), selectedFile);
  }
public static @Nullable GitRepository guessWidgetRepository(@NotNull Project project, @Nullable VirtualFile selectedFile)