Commit a41e354a authored by Chris Bracken's avatar Chris Bracken Committed by GitHub

Emit CocoaPods output if pod install fails (#11018)

In the case where the CocoaPods 'pod install' step fails, emit its
stdout to provide any potentially-useful error messages to the user.
parent cb4a54db
...@@ -434,16 +434,15 @@ Future<Null> _runPodInstall(Directory bundle, String engineDirectory) async { ...@@ -434,16 +434,15 @@ Future<Null> _runPodInstall(Directory bundle, String engineDirectory) async {
); );
return; return;
} }
try { final Status status = logger.startProgress('Running pod install...', expectSlowOperation: true);
final Status status = logger.startProgress('Running pod install...', expectSlowOperation: true); final ProcessResult result = await processManager.run(
await runCheckedAsync( <String>['pod', 'install'],
<String>['pod', 'install'], workingDirectory: bundle.path,
workingDirectory: bundle.path, environment: <String, String>{'FLUTTER_FRAMEWORK_DIR': engineDirectory},
environment: <String, String>{'FLUTTER_FRAMEWORK_DIR': engineDirectory}, );
); status.stop();
status.stop(); if (result.exitCode != 0) {
} catch (e) { throwToolExit('Error running pod install:\n${result.stdout}');
throwToolExit('Error running pod install: $e');
} }
} }
} }
......
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