Пример #1
0
    protected override StepResult HandleResult(string?result, Queue <ConfigInitWizardStep> steps, Config config, string workingDirectory)
    {
        switch (result)
        {
        case "0":
            return(StepResult.SaveAndExit());

        case "1":
            return(StepResult.ExitWithoutSaving());

        case "2":
            steps.Enqueue(this.StepFactory.CreateStep <PickBranchingStrategyStep>());
            return(StepResult.Ok());

        case "3":
            steps.Enqueue(this.StepFactory.CreateStep <SetNextVersion>());
            return(StepResult.Ok());

        case "4":
            steps.Enqueue(this.StepFactory.CreateStep <ConfigureBranches>());
            return(StepResult.Ok());

        case "5":
            var editConfigStep = this.StepFactory.CreateStep <EditConfigStep>();
            steps.Enqueue(this.StepFactory.CreateStep <GlobalModeSetting>().WithData(editConfigStep, false));
            return(StepResult.Ok());

        case "6":
            steps.Enqueue(this.StepFactory.CreateStep <AssemblyVersioningSchemeSetting>());
            return(StepResult.Ok());

        case "7":
            steps.Enqueue(this.StepFactory.CreateStep <SetupBuildScripts>());
            return(StepResult.Ok());
        }
        return(StepResult.InvalidResponseSelected());
    }