[tools] adds 'android' alias for build-example script (#3656)

[tools] adds 'android' alias for build-example script
This commit is contained in:
Tarrin Neal
2023-04-06 13:59:04 -07:00
committed by GitHub
parent 36d412490a
commit ecdc685786
5 changed files with 87 additions and 2 deletions

View File

@ -39,6 +39,8 @@ const String _flutterBuildTypeMacOS = 'macos';
const String _flutterBuildTypeWeb = 'web';
const String _flutterBuildTypeWindows = 'windows';
const String _flutterBuildTypeAndroidAlias = 'android';
/// A command to build the example applications for packages.
class BuildExamplesCommand extends PackageLoopingCommand {
/// Creates an instance of the build command.
@ -52,7 +54,8 @@ class BuildExamplesCommand extends PackageLoopingCommand {
argParser.addFlag(platformWeb);
argParser.addFlag(platformWindows);
argParser.addFlag(platformIOS);
argParser.addFlag(_platformFlagApk);
argParser.addFlag(_platformFlagApk,
aliases: const <String>[_flutterBuildTypeAndroidAlias]);
argParser.addOption(
kEnableExperiment,
defaultsTo: '',