public Site menu(Menu menu) { Menu = menu; return this; }
public static Site make(dynamic parameters) { var commentProvider = new IntenseDebateCommentProvider("9c0758183a14e567cb74c0d8c265f005"); var searchProvider = new GoogleCustomSearchProvider("005424054565942892879:knukodny3cw"); var site = new Site("Replicator.org", "www.replicator.org", parameters); var homePage = new Page("home", "About"); var journal = new Journal("journal", "Journal", "Armin's Journal"); journal .comments(commentProvider) .search(searchProvider); var twitter = new ExternalPage("connect", "Twitter", "http://www.twitter.com/pragmatrix"); var projects = new Page("projects", "Projects"); var github = new ExternalPage("github", "Github", "http://www.github.com/pragmatrix"); var bookmarks = new ExternalPage("bookmarks", "Bookmarks", "https://pinboard.in/u:pragmatrix"); var xing = new ExternalPage("xing", "Xing", "http://www.xing.com/profile/Armin_Sander"); var page404 = new Page("404", "Page Not Found, Error 404"); var feedRef = new ExternalPage("feed", "", "/" + journal.FeedSitePath); feedRef.referenceClass("icon-rss"); var menu = new Menu(); menu .page(homePage) .page(projects) .page(journal.indexReference("Journal")) .page(github) .page(twitter) .page(xing) .page(bookmarks) .page(feedRef); site .page(page404) .css("replicator.css") // nice header font: Orbitron, but less readable than Audiowide .cssRef("https://fonts.googleapis.com/css?family=Questrial|Ubuntu+Mono|Audiowide") .slogan("... live programming is next") .home(homePage) .menu(menu) .journal(journal) .loadContentFromDirectory("Pages") .fontAwesome(); // this should be part of the site generator! using (var f = File.Open("Site/moved-permanently", FileMode.Create, FileAccess.Write)) using (var writer = new StreamWriter(f)) { writer.WriteLine("Redirect permanent /node/feed /journal/feed"); forwardOldContentPages(writer); forwardNodePages(writer); } return site; }
public Site footerMenu(Menu menu) { FooterMenu = menu; return this; }