Commit 5a9b8b77 authored by Jason Simmons's avatar Jason Simmons Committed by GitHub

Do not print the output of the package dependency tool during hot reload (#6494)

parent d17e80ce
...@@ -151,14 +151,16 @@ bool exitsHappy(List<String> cli) { ...@@ -151,14 +151,16 @@ bool exitsHappy(List<String> cli) {
/// Throws an error if cmd exits with a non-zero value. /// Throws an error if cmd exits with a non-zero value.
String runCheckedSync(List<String> cmd, { String runCheckedSync(List<String> cmd, {
String workingDirectory, String workingDirectory,
bool allowReentrantFlutter: false bool allowReentrantFlutter: false,
bool hideStdout: false,
}) { }) {
return _runWithLoggingSync( return _runWithLoggingSync(
cmd, cmd,
workingDirectory: workingDirectory, workingDirectory: workingDirectory,
allowReentrantFlutter: allowReentrantFlutter, allowReentrantFlutter: allowReentrantFlutter,
hideStdout: hideStdout,
checked: true, checked: true,
noisyErrors: true noisyErrors: true,
); );
} }
...@@ -186,7 +188,8 @@ String _runWithLoggingSync(List<String> cmd, { ...@@ -186,7 +188,8 @@ String _runWithLoggingSync(List<String> cmd, {
bool checked: false, bool checked: false,
bool noisyErrors: false, bool noisyErrors: false,
String workingDirectory, String workingDirectory,
bool allowReentrantFlutter: false bool allowReentrantFlutter: false,
bool hideStdout: false,
}) { }) {
_traceCommand(cmd, workingDirectory: workingDirectory); _traceCommand(cmd, workingDirectory: workingDirectory);
ProcessResult results = Process.runSync( ProcessResult results = Process.runSync(
...@@ -198,7 +201,7 @@ String _runWithLoggingSync(List<String> cmd, { ...@@ -198,7 +201,7 @@ String _runWithLoggingSync(List<String> cmd, {
printTrace('Exit code ${results.exitCode} from: ${cmd.join(' ')}'); printTrace('Exit code ${results.exitCode} from: ${cmd.join(' ')}');
if (results.stdout.isNotEmpty) { if (results.stdout.isNotEmpty && !hideStdout) {
if (results.exitCode != 0 && noisyErrors) if (results.exitCode != 0 && noisyErrors)
printStatus(results.stdout.trim()); printStatus(results.stdout.trim());
else else
......
...@@ -57,7 +57,7 @@ class StartupDependencySetBuilder { ...@@ -57,7 +57,7 @@ class StartupDependencySetBuilder {
String output; String output;
try { try {
output = runCheckedSync(args); output = runCheckedSync(args, hideStdout: true);
} catch (e) { } catch (e) {
return null; return null;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment