@Override
  public @Nullable RepositoryLocation getLocationFor(@NotNull FilePath rootPath) {
    VirtualFile gitRoot = rootPath.getVirtualFile();
    if (gitRoot == null) return null;

    GitRepository repository = GitUtil.getRepositoryManager(myProject).getRepositoryForRoot(gitRoot);
    if (repository == null) {
      LOG.info("No GitRepository for " + gitRoot);
      return null;
    }
    GitLocalBranch currentBranch = repository.getCurrentBranch();
    if (currentBranch == null) {
      return null;
    }
    GitRemoteBranch trackedBranch = currentBranch.findTrackedBranch(repository);
    if (trackedBranch == null) {
      return null;
    }
    File rootFile = new File(gitRoot.getPath());
    return new GitRepositoryLocation(trackedBranch.getRemote().getFirstUrl(), rootFile);
  }
@Override
  public @Nullable RepositoryLocation getLocationFor(@NotNull FilePath rootPath)