boolean (@NotNull Collection<? extends GitRepository> roots, @Nullable @NlsContexts.NotificationTitle String errorNotificationTitle, boolean notifySuccess) { MultiRootMessage additionalInfo = new MultiRootMessage(myProject, GitUtil.getRootsFromRepositories(roots), false, true); for (GitRepository repository : roots) { LOG.info("fetching " + repository); GitFetchResult result = fetch(repository); String ai = result.getAdditionalInfo(); if (!StringUtil.isEmptyOrSpaces(ai)) { additionalInfo.append(repository.getRoot(), ai); } if (!result.isSuccess()) { Collection<Exception> errors = new ArrayList<>(getErrors()); errors.addAll(result.getErrors()); displayFetchResult(myProject, result, errorNotificationTitle, errors); return false; } } if (notifySuccess) { VcsNotifier.getInstance(myProject).notifySuccess(FETCH_SUCCESS, "", GitBundle.message("notification.content.fetched.successfully")); } if (!additionalInfo.asString().isEmpty()) { VcsNotifier.getInstance(myProject) .notifyMinorInfo(FETCH_DETAILS, GitBundle.message("notification.title.fetch.details"), additionalInfo.asString()); } return true; }