Remove unused pushFile methods in ios classes (#13215)

This commit is contained in:
Todd Volkert
2017-11-27 12:55:59 -08:00
committed by GitHub
parent c25558d426
commit c182e0e517
2 changed files with 0 additions and 46 deletions

View File

@@ -43,16 +43,10 @@ class IOSDevice extends Device {
IOSDevice(String id, { this.name, String sdkVersion }) : _sdkVersion = sdkVersion, super(id) {
_installerPath = _checkForCommand('ideviceinstaller');
_iproxyPath = _checkForCommand('iproxy');
_pusherPath = _checkForCommand(
'ios-deploy',
'To copy files to iOS devices, please install ios-deploy. To install, run:\n'
'brew install ios-deploy'
);
}
String _installerPath;
String _iproxyPath;
String _pusherPath;
final String _sdkVersion;
@@ -302,25 +296,6 @@ class IOSDevice extends Device {
return false;
}
Future<bool> pushFile(ApplicationPackage app, String localFile, String targetFile) async {
if (platform.isMacOS) {
runSync(<String>[
_pusherPath,
'-t',
'1',
'--bundle_id',
app.id,
'--upload',
localFile,
'--to',
targetFile
]);
return true;
} else {
return false;
}
}
@override
Future<TargetPlatform> get targetPlatform async => TargetPlatform.ios;

View File

@@ -211,17 +211,6 @@ class IOSSimulator extends Device {
String get xcrunPath => fs.path.join('/usr', 'bin', 'xcrun');
String _getSimulatorPath() {
return fs.path.join(homeDirPath, 'Library', 'Developer', 'CoreSimulator', 'Devices', id);
}
String _getSimulatorAppHomeDirectory(ApplicationPackage app) {
final String simulatorPath = _getSimulatorPath();
if (simulatorPath == null)
return null;
return fs.path.join(simulatorPath, 'data');
}
@override
Future<bool> isAppInstalled(ApplicationPackage app) {
return SimControl.instance.isInstalled(id, app.id);
@@ -425,16 +414,6 @@ class IOSSimulator extends Device {
return false;
}
Future<bool> pushFile(
ApplicationPackage app, String localFile, String targetFile) async {
if (platform.isMacOS) {
final String simulatorHomeDirectory = _getSimulatorAppHomeDirectory(app);
await runCheckedAsync(<String>['cp', localFile, fs.path.join(simulatorHomeDirectory, targetFile)]);
return true;
}
return false;
}
String get logFilePath {
return fs.path.join(homeDirPath, 'Library', 'Logs', 'CoreSimulator', id, 'system.log');
}