Created
June 17, 2019 01:25
-
-
Save siennathesane/4472ace667d96fcd6aeb69160f425eca to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var target = Argument("target", "Welcome"); | |
| List<string> tasks = new List<string>(); | |
| Setup(context => { | |
| foreach(var task in context.TasksToExecute) { | |
| Information("task: {0}", task.Name); | |
| tasks.Append(task.Name); | |
| } | |
| }); | |
| Task("A").Description("Performs A").Does(() => {}); | |
| Task("B").Description("Performs B").Does(() => {}); | |
| Task("C").IsDependentOn("B").Description("Performs C after A and B").Does(() => {}); | |
| Task("Welcome") | |
| .Does(() => { | |
| Information("Welcome to the Build Environment. Please run one of the targets: {0}", string.Join(", ", tasks)); | |
| Environment.Exit(0); | |
| }); | |
| RunTarget(target); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment