static void Main(string[] args) { WikiDetails wikiDetails = WikiDetails.Empty(); if (args.Length > 1) { wikiDetails = ParseArgs(args); } if (string.IsNullOrEmpty(wikiDetails.BitBucketFolder)) { wikiDetails.BitBucketFolder = ConsoleArgumentPrompter.PromptUser("Please enter the bitbucket folder:"); } if (wikiDetails.PromptDescription) { wikiDetails.ProjectDescription = ConsoleArgumentPrompter.PromptUser("Please enter the project description:"); } if (args.Length < 2) { wikiDetails.ProjectName = ConsoleArgumentPrompter.PromptUser("Please enter the project name:"); wikiDetails.ProjectDescription = ConsoleArgumentPrompter.PromptUser("Please enter the project description:"); wikiDetails.OutputFolder = ConsoleArgumentPrompter.PromptUser("Please enter the output folder:"); wikiDetails.TemplateFolder = ConsoleArgumentPrompter.PromptUser("Please enter the template folder:"); } if (string.IsNullOrEmpty(wikiDetails.TemplateFolder)) { wikiDetails.TemplateFolder = defaultTemplateFolder; } //var wikiDetails = new WikiDetails(bitbucket, projectName, projectDescription); Console.WriteLine("Starting to compile your wiki..."); var wikiCompiler = new WikiCompiler(wikiDetails); wikiCompiler.ExportWiki(wikiDetails.OutputFolder); ConsoleArgumentPrompter.PromptUser($"Wiki skeleton compiled.\nPlease see {wikiDetails.OutputFolder} for you wiki.\nPress any key to exit."); }
public WikiCompiler(WikiDetails wikiDetails) { this.wikiDetails = wikiDetails; this.wikiTemplateFolder = wikiDetails.TemplateFolder; }