Beispiel #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(new PickBranchingStrategyStep(Console, FileSystem));
                return(StepResult.Ok());

            case "3":
                steps.Enqueue(new SetNextVersion(Console, FileSystem));
                return(StepResult.Ok());

            case "4":
                steps.Enqueue(new ConfigureBranches(Console, FileSystem));
                return(StepResult.Ok());

            case "5":
                steps.Enqueue(new GlobalModeSetting(new EditConfigStep(Console, FileSystem), false, Console, FileSystem));
                return(StepResult.Ok());

            case "6":
                steps.Enqueue(new AssemblyVersioningSchemeSetting(Console, FileSystem));
                return(StepResult.Ok());

            case "7":
                steps.Enqueue(new AssemblyInformationalVersioningSchemeSetting(Console, FileSystem));
                return(StepResult.Ok());

            case "8":
                steps.Enqueue(new SetupBuildScripts(Console, FileSystem));
                return(StepResult.Ok());
            }
            return(StepResult.InvalidResponseSelected());
        }
Beispiel #2
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(StepFactory.CreateStep <PickBranchingStrategyStep>());
                return(StepResult.Ok());

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

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

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

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

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