internal static void InstallLatestOneSignalRelease() { if (IsOneSignalCoreInstalled) { EditorApplication.delayCall += () => { EditorUtility.DisplayDialog("Successes", "OneSignal installation completed. Thank you!", "Ok"); UninstallBootstrapper(); }; return; } if (FindRemainingDirectoriesOfOutdatedSDK(out var directories)) { if (EditorUtility.DisplayDialog("OneSignal", "The project contains an outdated version of OneSignal SDK! It has to be removed in order to continue the installation.", "Remove and continue", "Cancel installation")) { CleanUpUtility.RemoveDirectories(directories); } else { EditorApplication.delayCall += UninstallBootstrapper; return; } } else { EditorUtility.DisplayDialog("OneSignal", "Installation started. Thank you!", "Ok"); } GitHubUtility.GetLatestRelease(BootstrapperConfig.GitHubRepositoryURL, Bootstrap); }
static void UninstallBootstrapper() { UnityEditor.PackageManager.Client.Remove(BootstrapperConfig.BootstrapperPackageName); CleanUpUtility.RemoveDirectories(BootstrapperConfig.BootstrapperFolderPath); }