[flutter_tools] inject output preferences at the top level (#58875)
The tool was setting the output preferences in a sub-context. Originally these were not injected before the arg parsers were created, though that was fixed by the lazy command creation. Once local engine is removed, the inner flutter_command Zone can be removed.
This commit is contained in:
@@ -11,6 +11,7 @@ import 'src/base/template.dart';
|
||||
// The build_runner code generation is provided here to make it easier to
|
||||
// avoid introducing the dependency into google3. Not all build* packages
|
||||
// are synced internally.
|
||||
import 'src/base/terminal.dart';
|
||||
import 'src/build_runner/build_runner.dart';
|
||||
import 'src/build_runner/mustache_template.dart';
|
||||
import 'src/build_runner/resident_web_runner.dart';
|
||||
@@ -135,6 +136,11 @@ Future<void> main(List<String> args) async {
|
||||
stdio: globals.stdio,
|
||||
terminal: globals.terminal,
|
||||
outputPreferences: globals.outputPreferences,
|
||||
))
|
||||
)),
|
||||
OutputPreferences: () => OutputPreferences.fromArguments(
|
||||
args,
|
||||
stdio: globals.stdio,
|
||||
userMessages: globals.userMessages,
|
||||
),
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user