From f5af7f468ee2be38d8f437b30f6977bd6908fd6a Mon Sep 17 00:00:00 2001 From: rosen-vladimirov Date: Wed, 3 Feb 2016 00:27:41 +0200 Subject: [PATCH] Fix livesync on Android devices and Genymotion emulator The following fix has been applied in common lib: On some Android devices the `android-runtime` cannot delete the files in `/data/local/tmp//fullsync` directory. The next time when the application is started, runtime reads the fullsync directory and replaces the real application with content of fullsync dir. So the app does not start as it is not full app. Fix two issues - first one is missing `chmod` command in the file that we are generating. As we cannot spawn chmod of all files directly, due to some command line limitations, we are writing the command in a file, transfer the file on the device and execute it. BUT, we've lost the command in this commit https://github.com/telerik/mobile-cli-lib/commit/6d52c6ab9b51aaac7b5fae7e4412c0f58737fcf1 In fact our file contains only list of files and when trying to execute it on the device, we receive error, but we have added parameter to `spawnFromEvent` not to throw. So the error is hidden. Add the missing chmod, so the command can be executed successfully. However this fixes the issues for some files, but when we have directories, we do not write them in the file, so android runtime does not have permissions to delete them and they remain in fullsync directory. Fix this by including directories in the list of application files (not sure if this will not break something else). --- lib/common | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/common b/lib/common index d7719134bb..7ba45ead4a 160000 --- a/lib/common +++ b/lib/common @@ -1 +1 @@ -Subproject commit d7719134bb7f9b71bf682670c6c02ad89de03ac2 +Subproject commit 7ba45ead4ac61c0c4e6a6d97d5446dffae8db19c