/*
 * The MIT License (MIT)
 *
 * Copyright (c) 2015 Clever Cloud, SAS
 *
 * Permission is hereby granted, free of charge, to any person obtaining a copy
 * of this software and associated documentation files (the "Software"), to deal
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in all
 * copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 * SOFTWARE.
 */

package com.cleverCloud.cleverIdea.utils;

import com.intellij.openapi.project.Project;
import git4idea.config.GitVcsApplicationSettings;
import git4idea.config.GitVersion;
import git4idea.i18n.GitBundle;
import org.jetbrains.plugins.github.util.GithubNotifications;

public class GitUtils {
  public static boolean testGitExecutable(Project project) {
    GitVcsApplicationSettings settings = GitVcsApplicationSettings.getInstance();
    String executable = settings.getPathToGit();

    GitVersion version;
    try {
      version = GitVersion.identifyVersion(executable);
    } catch (Exception var5) {
      GithubNotifications.showErrorDialog(project, GitBundle.getString("find.git.error.title"), var5);
      return false;
    }

    if(!version.isSupported()) {
      GithubNotifications.showWarningDialog(project, GitBundle.message("find.git.unsupported.message", version.toString(), GitVersion.MIN), GitBundle.getString("find.git.success.title"));
      return false;
    } else {
      return true;
    }
  }
}

@@ -1187,16 +1187,114 @@
 utils;%0A%0A
+import com.intellij.notification.Notification;%0Aimport com.intellij.notification.NotificationType;%0A
 import c
@@ -1418,102 +1418,8 @@
 ion;
-%0Aimport git4idea.i18n.GitBundle;%0Aimport org.jetbrains.plugins.github.util.GithubNotifications;
 %0A%0Apu
@@ -1728,16 +1728,20 @@
 );%0A    %7D
+%0A   
  catch (
@@ -1756,38 +1756,36 @@
 n var5) %7B%0A      
-Github
+new 
 Notifications.sh
@@ -1784,84 +1784,202 @@
 tion
-s.showErrorDialog(project, GitBundle.getString(%22find.git.error.title%22), var5
+(%22Vcs Important Messages%22, %22Git executable can't be found%22,%0A                       %22The git executable ca not be found. Please check your settings.%22, NotificationType.INFORMATION).notify(project
 );%0A 
@@ -2010,16 +2010,17 @@
 %0A%0A    if
+ 
 (!versio
@@ -2048,14 +2048,12 @@
     
-Github
+new 
 Noti
@@ -2064,169 +2064,170 @@
 tion
-s.showWarningDialog(project
+(%22Vcs Important Messages%22
 , 
+%22
 Git
-Bundle.message(%22find.git.unsupported.message%22, version.toString(), GitVersion.MIN), GitBundle.getString(%22find.git.success.title%22)
+ version unsupported%22,%0A                       %22Your version of git is not supported.%22, NotificationType.INFORMATION).notify(project
 );%0A 
@@ -2250,16 +2250,20 @@
 e;%0A    %7D
+%0A   
  else %7B%0A

Remove GitHub plugin references