Created
May 19, 2015 06:15
-
-
Save davidfowl/0fc85f3215adf4eab294 to your computer and use it in GitHub Desktop.
project structure DSL in C# 6.0
This file contains 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
public class Program | |
{ | |
public void Main() | |
{ | |
var solution = new Directory | |
{ | |
["global.json"] = new JObject | |
{ | |
["projects"] = new JArray { "src", "test" } | |
}, | |
["src"] = new Directory | |
{ | |
["MyProject"] = new Directory | |
{ | |
["Startup.cs"] = "public class Startup { }", | |
["project.json"] = new JObject | |
{ | |
["dependencies"] = new JObject | |
{ | |
["Newtonsoft.Json"] = "6.0.6" | |
}, | |
["frameworks"] = new JObject | |
{ | |
["dnx451"] = new JObject { } | |
} | |
} | |
} | |
} | |
}; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment