CompletableFuture<CliResult> (@NotNull Object fileOrProject, @NotNull @NlsContexts.NotificationContent String notificationText) { LOG.info(notificationText); final CompletableFuture<CliResult> result = new CompletableFuture<>(); myFileOrProjectToCallback.put(fileOrProject, result); Notifications.Bus.notify(new Notification(Notifications.SYSTEM_MESSAGES_GROUP_ID, IdeBundle.message("notification.title.activated.from.command.line"), notificationText, NotificationType.WARNING).setImportant(true)); EditorNotifications.updateAll(); return result; }