private static void WriteAdbPathVersions(string[] pathDirs, StreamWriter writer)
 {
     // Search through directories in PATH to find the version of adb used from PATH
     foreach (var path in pathDirs)
     {
         string fullAdbPath = Path.Combine(path, ShellHelper.GetAdbFileName());
         if (File.Exists(fullAdbPath))
         {
             WriteCommand(fullAdbPath, "version", writer);
         }
     }
 }
Beispiel #2
0
 private static void WriteAdbPathVersions(string[] pathDirs, StreamWriter writer)
 {
     // Search through directories in PATH to find the version of adb used from PATH
     foreach (var path in pathDirs)
     {
         // Ignore paths that contain illegal characters.
         if (path.IndexOfAny(Path.GetInvalidPathChars()) == -1)
         {
             string fullAdbPath = Path.Combine(path, ShellHelper.GetAdbFileName());
             if (File.Exists(fullAdbPath))
             {
                 WriteCommand(fullAdbPath, "version", writer);
             }
         }
     }
 }