@@ -55,11 +55,7 @@ public static void Run(
5555 . Create (
5656 Resolve ( Validate ( name ) ) ,
5757 args ,
58- #if NET8_0_OR_GREATER
5958 [ ] ,
60- #else
61- Enumerable . Empty < string > ( ) ,
62- #endif
6359 workingDirectory ,
6460 false ,
6561 configureEnvironment ?? defaultAction ,
@@ -176,11 +172,7 @@ public static Task RunAsync(
176172 . Create (
177173 Resolve ( Validate ( name ) ) ,
178174 args ,
179- #if NET8_0_OR_GREATER
180175 [ ] ,
181- #else
182- Enumerable . Empty < string > ( ) ,
183- #endif
184176 workingDirectory ,
185177 false ,
186178 configureEnvironment ?? defaultAction ,
@@ -296,11 +288,7 @@ private static async Task RunAsync(
296288 . Create (
297289 Resolve ( Validate ( name ) ) ,
298290 args ,
299- #if NET8_0_OR_GREATER
300291 [ ] ,
301- #else
302- Enumerable . Empty < string > ( ) ,
303- #endif
304292 workingDirectory ,
305293 true ,
306294 configureEnvironment ?? defaultAction ,
@@ -388,13 +376,8 @@ private static async Task RunAsync(
388376 await process . StandardInput . WriteAsync ( standardInput ) . ConfigureAwait ( false ) ;
389377 process . StandardInput . Close ( ) ;
390378
391- #if NET8_0_OR_GREATER
392379 readOutput = process . StandardOutput . ReadToEndAsync ( cancellationToken ) ;
393380 readError = process . StandardError . ReadToEndAsync ( cancellationToken ) ;
394- #else
395- readOutput = process . StandardOutput . ReadToEndAsync ( ) ;
396- readError = process . StandardError . ReadToEndAsync ( ) ;
397- #endif
398381 }
399382 catch ( Exception )
400383 {
@@ -443,11 +426,7 @@ private static string Resolve(string name)
443426
444427 var searchFileNames = string . IsNullOrEmpty ( extension )
445428 ? windowsExecutableExtensions . Select ( ex => Path . ChangeExtension ( name , ex ) ) . ToList ( )
446- #if NET8_0_OR_GREATER
447429 : [ name ] ;
448- #else
449- : new List < string > { name , } ;
450- #endif
451430
452431 var path = GetSearchDirectories ( ) . SelectMany ( _ => searchFileNames , Path . Combine )
453432 . FirstOrDefault ( File . Exists ) ;
0 commit comments