static Option <CliArguments> Validate(CliArguments args) { var badDirs = args.Directories.Filter(dir => !Directory.Exists(dir)).ToList(); if (badDirs.Count > 0) { Console.Error.WriteLine("Can not find following directories:"); badDirs.ForEach(Console.Error.WriteLine); return(None); } return(args); }
public CliEnvironment(CliArguments args, Action <string> writeInfoLine, Action <double> updateProgress) { Args = args; WriteInfoLine = writeInfoLine; UpdateProgress = updateProgress; }