Skip to content
This repository was archived by the owner on Nov 9, 2018. It is now read-only.

Commit 4268d33

Browse files
author
Victor Hurdugaci
committed
Get only the first line of there where command because there might be multiple results
1 parent 0d950a7 commit 4268d33

File tree

1 file changed

+3
-1
lines changed
  • src/Microsoft.Dnx.TestHost.Client.Sources

1 file changed

+3
-1
lines changed

src/Microsoft.Dnx.TestHost.Client.Sources/DNX.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,9 @@ public static string FindDnx()
2323

2424
process.Start();
2525
process.WaitForExit();
26-
return process.StandardOutput.ReadToEnd().TrimEnd('\r', '\n');
26+
// Get the first result only. Workaround for multiple results until IRuntimeEnvironment
27+
// exposes the path to DNX
28+
return process.StandardOutput.ReadLine().TrimEnd('\r', '\n');
2729
}
2830

2931
public static string FindDnxDirectory()

0 commit comments

Comments
 (0)