static void DumpMeta(SiteMetaInformation metaInfo) { Logger.Normal("Uri: {0}", metaInfo.Url); Logger.Normal("Title: {0}", metaInfo.Title); Logger.Normal("Description: {0}", metaInfo.Description); Logger.Normal("ImageUrl: {0}", metaInfo.ImageUrl); Logger.Normal("Author: {0}", metaInfo.Author); Logger.Normal("Name: {0}", metaInfo.SiteName); Logger.Normal("Type: {0}", metaInfo.Type); Logger.Normal("Tags: {0}", String.Join(", ", metaInfo.Tags)); }
public void BootstrapUrl(Uri url) { var metaInfo = SiteMetaInformation.FromUrl(url); var(date, newsFile) = FindFreeSlot(); var content = FormatNews(date, metaInfo); Info($"Create news file: {Path.GetFileName(newsFile)}"); var uft8 = new UTF8Encoding(false); File.WriteAllText(newsFile, content, uft8); }