34 | Last updated: 35 |
36 | 37 |-
41 |
- 42 | 43 | () 44 | 45 | 46 |
7 | Welcome to the Nancy Samples site! 8 |
9 |10 | This site/demo shows a simple Nancy website that aggregates Nancy demo projects from multiple GitHub accounts that follow the 11 | Nancy.Demo.xxxx naming convention. 12 |
13 |15 | For rendering the views this site uses the SuperSimpleViewEngine, which is build into Nancy core, along with Knockout.js 16 | for binding data to the view. 17 |
18 |19 | On the storage front, we're using MongoDB, with the live samples site using MongoHQ. 20 | If you're running locally you will need to make sure you have a local instance of MongoDB running on your machine, or edit the Configuration.cs class and 21 | alter the connection string to point to your own MongoHQ account. 22 |
23 |It's pretty simple to create a sample for the site, but there's a few conventions you need to follow:
8 | 9 |Once you've done all that and pushed it up to Github, you just need to let us know, either:
23 | 24 | 28 | 29 |Once your account is added the site will automatically pickup any additional Demo projects you add.
30 | 31 |Have fun! :-)
32 | 33 |", value, "");
131 | });
132 |
133 | var renderer =
134 | new Markdown();
135 |
136 | return renderer.Transform(content);
137 | });
138 | }
139 |
140 |
141 | private string ExtractVersion(string owner, string repositoryName)
142 | {
143 | var relativeFilePath =
144 | string.Format("contents/src/{0}/Properties/AssemblyInfo.cs", repositoryName);
145 |
146 | return this.githubFileContentExtractor.Extract(owner, repositoryName, relativeFilePath, content =>
147 | {
148 | return !string.IsNullOrWhiteSpace(content)
149 | ? this.assemblyVersionPattern.Match(content).Groups["version"].Value
150 | : string.Empty;
151 | });
152 | }
153 | }
154 | }
--------------------------------------------------------------------------------
/src/Nancy.Demo.Samples/Nancy.Demo.Samples.csproj:
--------------------------------------------------------------------------------
1 |
2 | The requested content cannot be loaded.
Please try again later.