protected override void _runStep()
    {
        var manifest = new Manifest();

        manifest.Fetch();

        manifest.AddScopeRegistry(_scopeRegistry);

        var scopeRegistry = manifest.GetScopeRegistry(_registryUrl);

        scopeRegistry.AddScope(_packagesScope);

#if UNITY_2017_3_OR_NEWER
        manifest.ApplyChanges();

        var addRequest = UnityEditor.PackageManager.Client.Add(_coreVersion);
        while (!addRequest.IsCompleted)
        {
        }

        addRequest = UnityEditor.PackageManager.Client.Add(_androidVersion);
        while (!addRequest.IsCompleted)
        {
        }

        addRequest = UnityEditor.PackageManager.Client.Add(_iosVersion);
        while (!addRequest.IsCompleted)
        {
        }
#else
        manifest.AddDependency(_corePackageName, _coreVersion);
        manifest.AddDependency(_androidPackageName, _androidVersion);
        manifest.AddDependency(_iosPackageName, _iosVersion);

        manifest.ApplyChanges();
        AssetDatabase.Refresh();
#endif
        OneSignalSetupWindow.CloseWindow();
        SessionState.SetBool(_shouldShowWindowKey, true);
    }