Commit f5411d3
Check dotnet path without which or where first (#2234)
* Check dotnet without which or where first
Which and where can be slow to find. For the common case which we want to make fast, we can just check 'dotnet' first and see if that works.
Note: Ideally, this function would only return a string, but that would require writing a wrapper around this return type just for this function and does not follow the other existing patterns.
With respect to tests: This should be covered by the existing 'find path' tests.
* Utilize a finally block
Co-authored-by: Copilot <[email protected]>
---------
Co-authored-by: Copilot <[email protected]>1 parent de07136 commit f5411d3
File tree
2 files changed
+28
-0
lines changed- vscode-dotnet-runtime-extension/src
- vscode-dotnet-runtime-library/src/Acquisition
2 files changed
+28
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
515 | 515 | | |
516 | 516 | | |
517 | 517 | | |
| 518 | + | |
| 519 | + | |
| 520 | + | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
518 | 529 | | |
519 | 530 | | |
520 | 531 | | |
| |||
Lines changed: 17 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
92 | 92 | | |
93 | 93 | | |
94 | 94 | | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
95 | 112 | | |
96 | 113 | | |
97 | 114 | | |
| |||
0 commit comments