diff --git a/packages/flutter_tools/lib/src/base/file_system.dart b/packages/flutter_tools/lib/src/base/file_system.dart index f53f689ba6..5ec714b70e 100644 --- a/packages/flutter_tools/lib/src/base/file_system.dart +++ b/packages/flutter_tools/lib/src/base/file_system.dart @@ -29,7 +29,7 @@ void ensureDirectoryExists(String filePath) { try { fs.directory(dirPath).createSync(recursive: true); } on FileSystemException catch (e) { - throwToolExit('Failed to create directory "$dirPath".\n$e'); + throwToolExit('Failed to create directory "$dirPath": ${e.osError.message}'); } }