// Path: src/main/java/gitflow/ui/NotifyUtil.java
// public class NotifyUtil
// {
//     private static final NotificationGroup TOOLWINDOW_NOTIFICATION = NotificationGroup.toolWindowGroup(
//             "Gitflow Errors", ToolWindowId.VCS, true);
//     private static final NotificationGroup STICKY_NOTIFICATION = new NotificationGroup(
//             "Gitflow Errors", NotificationDisplayType.STICKY_BALLOON, true);
//     private static final NotificationGroup BALLOON_NOTIFICATION = new NotificationGroup(
//             "Gitflow Notifications", NotificationDisplayType.BALLOON, true);
// 
//     public static void notifySuccess(Project project, String title, String message) {
//         notify(NotificationType.INFORMATION, BALLOON_NOTIFICATION, project, title, message);
//     }
// 
// 	public static void notifyInfo(Project project, String title, String message) {
// 		notify(NotificationType.INFORMATION, TOOLWINDOW_NOTIFICATION, project, title, message);
// 	}
// 
//     public static void notifyError(Project project, String title, String message) {
//         notify(NotificationType.ERROR, TOOLWINDOW_NOTIFICATION, project, title, message);
//     }
// 
//     public static void notifyError(Project project, String title, Exception exception) {
//         notify(NotificationType.ERROR, STICKY_NOTIFICATION, project, title, exception.getMessage());
//     }
// 
//     private static void notify(NotificationType type, NotificationGroup group, Project project, String title, String message) {
//         group.createNotification(title, message, type, null).notify(project);
//     }
// }


import com.intellij.openapi.project.Project;
import com.intellij.openapi.util.Key;
import gitflow.ui.NotifyUtil;
package gitflow.actions;


public class GitflowErrorsListener extends GitflowLineHandler{

    boolean hasMergeError=false;

    GitflowErrorsListener(Project project){
        myProject=project;
    }

    @Override
    public void onLineAvailable(String line, Key outputType) {
        if (line.contains("'flow' is not a git command")) {
// Path: src/main/java/gitflow/ui/NotifyUtil.java
// public class NotifyUtil
// {
//     private static final NotificationGroup TOOLWINDOW_NOTIFICATION = NotificationGroup.toolWindowGroup(
//             "Gitflow Errors", ToolWindowId.VCS, true);
//     private static final NotificationGroup STICKY_NOTIFICATION = new NotificationGroup(
//             "Gitflow Errors", NotificationDisplayType.STICKY_BALLOON, true);
//     private static final NotificationGroup BALLOON_NOTIFICATION = new NotificationGroup(
//             "Gitflow Notifications", NotificationDisplayType.BALLOON, true);
// 
//     public static void notifySuccess(Project project, String title, String message) {
//         notify(NotificationType.INFORMATION, BALLOON_NOTIFICATION, project, title, message);
//     }
// 
// 	public static void notifyInfo(Project project, String title, String message) {
// 		notify(NotificationType.INFORMATION, TOOLWINDOW_NOTIFICATION, project, title, message);
// 	}
// 
//     public static void notifyError(Project project, String title, String message) {
//         notify(NotificationType.ERROR, TOOLWINDOW_NOTIFICATION, project, title, message);
//     }
// 
//     public static void notifyError(Project project, String title, Exception exception) {
//         notify(NotificationType.ERROR, STICKY_NOTIFICATION, project, title, exception.getMessage());
//     }
// 
//     private static void notify(NotificationType type, NotificationGroup group, Project project, String title, String message) {
//         group.createNotification(title, message, type, null).notify(project);
//     }
// }


// Path: src/main/java/gitflow/actions/GitflowErrorsListener.java
import com.intellij.openapi.project.Project;
import com.intellij.openapi.util.Key;
import gitflow.ui.NotifyUtil;

package gitflow.actions;


public class GitflowErrorsListener extends GitflowLineHandler{

    boolean hasMergeError=false;

    GitflowErrorsListener(Project project){
        myProject=project;
    }

    @Override
    public void onLineAvailable(String line, Key outputType) {
        if (line.contains("'flow' is not a git command")) {
            NotifyUtil.notifyError(myProject, "Error", "Gitflow is not installed");