Skip to content

Commit

Permalink
Fix build script output
Browse files Browse the repository at this point in the history
  • Loading branch information
MatthewLM committed Nov 30, 2023
1 parent 31b0fb5 commit a7f1f41
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions coinlib/bin/util.dart
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import 'dart:convert';
import 'dart:io';

Future<bool> cmdAvailable(String cmd) async {
Expand All @@ -18,18 +19,15 @@ Future<int> execWithStdio(

final process = await Process.start(
executable, arguments, workingDirectory: workingDir,
mode: (stdin == null)
? ProcessStartMode.inheritStdio
: ProcessStartMode.normal,
);

if (stdin != null) {
process.stdout.pipe(stdout);
process.stdin.write(stdin);
await process.stdin.flush();
await process.stdin.close();
}

await process.stdout.transform(utf8.decoder).forEach(stdout.write);

return await process.exitCode;

}
Expand Down

0 comments on commit a7f1f41

Please sign in to comment.