in src/Analyzer.Cli/CommandLineParser.cs [76:101]
private Command SetupAnalyzeTemplateCommand()
{
Command analyzeTemplateCommand = new Command(
"analyze-template",
"Analyze a single template");
analyzeTemplateCommand.AddArgument(
new Argument<FileInfo>(
"template-file-path",
"The path of the template to analyze"));
analyzeTemplateCommand.AddOption(
new Option<FileInfo>(
new[] { "-p", "--parameters-file-path" },
"The parameter file to use when parsing the specified template")
);
// Assign handler method
analyzeTemplateCommand.Handler = CommandHandler.Create(
GetType().GetMethod(
nameof(AnalyzeTemplateCommandHandler),
BindingFlags.Instance | BindingFlags.NonPublic),
this);
return analyzeTemplateCommand;
}