Convert build mode to lowercase in tool_backend (#40393)

On macOS and iOS, the build mode is converted to lowercase in the
Flutter-side script, allowing projects to pass configuration names
directly. This adds the same behavior to the tool_backend.dart script
currently used by Windows and Linux, so that Windows builds can do the
same (since the default configuration names used by VS, as in Xcode,
start with a capital letter).
This commit is contained in:
stuartmorgan 2019-09-12 19:13:42 -07:00 committed by GitHub
parent ba13aa943c
commit a7cfdbd3f3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -8,7 +8,7 @@ import 'package:path/path.dart' as path; // ignore: package_path_import.
/// Executes the required flutter tasks for a desktop build.
Future<void> main(List<String> arguments) async {
final String targetPlatform = arguments[0];
final String buildMode = arguments[1];
final String buildMode = arguments[1].toLowerCase();
final String projectDirectory = Platform.environment['PROJECT_DIR'];
final bool verbose = Platform.environment['VERBOSE_SCRIPT_LOGGING'] != null;