private void RunCommand (string line, string basePath) {
Regex regFile = new Regex (@":r\s+(?<file>.+)", RegexOptions.IgnoreCase);
var match = regFile.Match (line);
if (!match.Success) {
return;
}
var fileMatch = match.Groups ["file"];
if (fileMatch == null) {
return;
}
var filePath = GetFullFilePath(fileMatch.Value, basePath);
if (string.IsNullOrEmpty (filePath) || !File.Exists (filePath)) {
return;
}
ExecuteFile (filePath);
}