Skip to content
This repository was archived by the owner on Feb 2, 2021. It is now read-only.

Fix application glitches on iOS simulator after livesync #423

Merged
merged 1 commit into from
Aug 10, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion mobile/ios/ios-emulator-services.ts
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,9 @@ class IosEmulatorServices implements Mobile.IiOSSimulatorService {
private getApplicationPath(appIdentifier: string, runningSimulatorId: string): IFuture<string> {
return (() => {
let rootApplicationsPath = path.join(osenv.home(), `/Library/Developer/CoreSimulator/Devices/${runningSimulatorId}/data/Containers/Bundle/Application`);
if(!this.$fs.exists(rootApplicationsPath).wait()) {
rootApplicationsPath = path.join(osenv.home(), `/Library/Developer/CoreSimulator/Devices/${runningSimulatorId}/data/Applications`);
}
let applicationGuids = this.$fs.readDirectory(rootApplicationsPath).wait();
let result: string = null;
_.each(applicationGuids, applicationGuid => {
Expand Down Expand Up @@ -202,7 +205,7 @@ class IosEmulatorServices implements Mobile.IiOSSimulatorService {
syncAction(applicationPath);

try {
this.$childProcess.exec("killall -KILL launchd_sim").wait();
this.$childProcess.exec("killall launchd_sim").wait();
this.$childProcess.exec(`xcrun simctl launch ${runningSimulatorId} ${appIdentifier}`).wait();
} catch(e) {
this.$logger.trace("Unable to kill simulator: " + e);
Expand Down