protected void OnFoundVBox(VagrantFile vagFileFound) { if (vagFileFound != null) { FoundVagrantFile(vagFileFound); } }
public List <VagrantFile> FindVagrantFiles() { string[] files = Directory.GetFiles(this.StartingDirectory, "Vagrantfile", SearchOption.AllDirectories); List <VagrantFile> vagrantFiles = new List <VagrantFile>(); foreach (string file in files) { //Console.WriteLine(file); VagrantFile vagrantFile = new VagrantFile(file); vagrantFiles.Add(vagrantFile); OnFoundVBox(vagrantFile); } return(vagrantFiles); }
static void DisplayVagrantFileFound(VagrantFile vagFileFound) { vagFilesFound += 1; Console.WriteLine("Vagrant files found: " + vagFilesFound + " (" + vagFileFound.GetFileFolder() + ")"); }