Add all runtime mode to custom-devices (#34)

* Add all runtime mode to custom-devices

* code format
This commit is contained in:
Hidenori Matsubayashi
2021-07-30 14:47:45 +09:00
committed by GitHub
parent f711cc0a70
commit feef220fb9
+6 -5
View File
@@ -80,6 +80,7 @@ class ELinuxDevice extends Device {
final ELinuxLogReader _logReader = ELinuxLogReader(); final ELinuxLogReader _logReader = ELinuxLogReader();
int _forwardedHostPort; int _forwardedHostPort;
BuildMode _buildMode = BuildMode.debug;
@override @override
Future<bool> get isLocalEmulator async => false; Future<bool> get isLocalEmulator async => false;
@@ -96,9 +97,10 @@ class ELinuxDevice extends Device {
} }
@override @override
bool supportsRuntimeMode(BuildMode buildMode) => _desktop bool supportsRuntimeMode(BuildMode buildMode) {
? buildMode != BuildMode.jitRelease _buildMode = buildMode;
: buildMode == BuildMode.debug; return buildMode != BuildMode.jitRelease;
}
@override @override
Future<String> get sdkNameAndVersion async => Future<String> get sdkNameAndVersion async =>
@@ -123,8 +125,7 @@ class ELinuxDevice extends Device {
return false; return false;
} }
final String bundlePath = final String bundlePath = app.outputDirectory(_buildMode, _targetArch);
app.outputDirectory(BuildMode.fromName('debug'), _targetArch);
final bool result = final bool result =
await tryInstall(localPath: bundlePath, appName: app.name); await tryInstall(localPath: bundlePath, appName: app.name);