[TOOL][SCRIPT] AndSync - Synchronize Backup and Restore Android Devices

wizwin

Senior Member
Nov 22, 2010
192
212
73
Bangalore
www.winnyonnet.ml
AndSync v1.3

About AndSync

This script helps you to:
- Synchronize applications if you have multiple android devices.
- Backup and Restore applications in batch.
- Un-install applications in batch.
- Backup and Restore application data on rooted and non-rooted (only for ICS and above) devices.
- Use your PC or Laptop to perform full backups. There is no need to first backup on SD card and then copy to your PC.

Why did I develop this?

1. I own multiple android phones with about 200 apps installed (I have no idea why :p) and it has become difficult to manage application updates from Play Store on these devices.

2. I needed a quick and easy way to backup applications directly to my computer and restore them after I do a full re-flash.

What are the prerequisites for this script?

  • Android SDK (ADB shell)
  • Perl v5.10.1 (Any latest version of Perl would also be fine)

Note: I used these versions, it may work on older versions as well but I have not tested those.

Installing prerequisites

- Install Perl from here
- Install Zip for Perl (Ubuntu Users) - sudo apt-get install libarchive-zip-perl
- Install adb using instructions from here

On which Desktop/Laptop OSes will this tool work?

It is a Perl script and so it should work on all OSes that can run Perl. Of course Android SDK port (at-least for adb) should exist.

For which versions of Android will this tool work?

I have come across 'adb backup' and 'restore' commands but that is not available for older/all devices. Using this tool you can perform backup and restore of devices with Android Gingerbread and above. (I have only tested using GB and JB). Froyo devices are not supported in the current version.

Where can you find this tool?

Here is the link [AndSync]. You can just download the Perl script 'AndSync.pl' and execute it if you have Perl installed.

From AndSync v1.3 the script can be updated automatically from Settings->'Update this script'.

Known Issues
- Some operations spit out too much information on console.
- Does not support Froyo devices at the moment.

If you have issues with market links try:
Settings->Applications->Manage Applications->All->Google Play Store->Force Stop & Clear Data

Please share your thoughts and suggestions for improvement. Please open issues on Github so that it can be tracked.

Enjoy Android !!
 

Attachments

Last edited:

desalesouche

Senior Member
Feb 6, 2012
3,651
4,294
0
do you think i can restore a system app with it....will try this week end on huawei honor u8660...thx
can you upload Perl v5.10.1 please....
 
Last edited:

thebeastglasser

Senior Member
Mar 11, 2012
290
79
0
Trying this out. I wonder how the speed compares to Titanium in terms of speed.

EDIT: As of right now, it doesn't recognize my 3VO running Gangnam Style CM10. Will test again after flashing Sense 4.1.
 
Last edited:

wizwin

Senior Member
Nov 22, 2010
192
212
73
Bangalore
www.winnyonnet.ml
Great tool, thanks!
Thank you for your review!

do you think i can restore a system app with it....will try this week end on huawei honor u8660...thx
can you upload Perl v5.10.1 please....
You can restore system apps if your phone is rooted. Currently all operation are done in batch there is no option to restore only a selected app (you can delete all unwanted apps (keep the only one you want to restore) from the Backup directory and get it done).

Trying this out. I wonder how the speed compares to Titanium in terms of speed.

EDIT: As of right now, it doesn't recognize my 3VO running Gangnam Style CM10. Will test again after flashing Sense 4.1.
Thank you for trying out this tool. I have not done any comparisons yet. I had tested it on Motorola Defy with CM10. For ICS and up there is an alternate backup restore support as well.

Please post your suggestions for improvement.
 

Nemo Aeternamn

Senior Member
Jul 25, 2011
63
41
0
Mo-ab
awesome... multiple devices? very nice... my brother in law was just wanting me to reset his phone to factory so he can take the latest update... and with my gnex... can't wait to give try this out
 
Last edited:

jacktackle

Senior Member
Jan 28, 2009
1,102
394
0
London
[
cant get it work

1)downloaded perl 5.16.1 and extracted to d:
2)downloaded andsync files and copied to a folder in d:
3)adb already in d:

tried your command from all the places. din't work. please some more guidance i'm sure there are more ppl like me :p

thanks for your help. i'm on win7 and One X already connected through usb debuging
 

paccer

Member
Jul 26, 2009
31
10
0
[
cant get it work

1)downloaded perl 5.16.1 and extracted to d:
2)downloaded andsync files and copied to a folder in d:
3)adb already in d:

tried your command from all the places. din't work. please some more guidance i'm sure there are more ppl like me :p

thanks for your help. i'm on win7 and One X already connected through usb debuging
You need to add adb and/or perl to your path variable:

Find the directory you installed perl and/or adb to, and add it to your path variable using this guide:
http://www.computerhope.com/issues/ch000549.htm

to check if its working properly (optional):

open up cmd (press win+r, then type cmd and press enter)
type adb
if it outputs info, then adb is working
type perl -v
if it outputs info, then perl is working

if you get
Code:
'<command>' is not recognized as an internal or external command,
operable program or batch file.
Then andsync script wont be able to find the needed programs

if this is in place, you should be able to double click the file or type perl <path>\AndSync.pl from within cmd prompt :highfive:
 
Last edited:

paccer

Member
Jul 26, 2009
31
10
0
Wizwin, great script! :good:
I would like to request that the script gives a warning, or even the choice to make multiple backups when backing up for a second time
i did it twice in a row to test, and it just overwrote the first backup without warning - this could result in very unfortunate things for some people

Also, handling of multiple backups would be neat :)
 

wizwin

Senior Member
Nov 22, 2010
192
212
73
Bangalore
www.winnyonnet.ml
Wizwin, great script! :good:
I would like to request that the script gives a warning, or even the choice to make multiple backups when backing up for a second time
i did it twice in a row to test, and it just overwrote the first backup without warning - this could result in very unfortunate things for some people

Also, handling of multiple backups would be neat :)
Thank you. Sure I will add that as an enhancement in the next release. I was waiting for requirements to come up.
 
Last edited:

paccer

Member
Jul 26, 2009
31
10
0
Please note: This apparently currently breaks android market links
I used titanium backup pro to restore them

Without, i guess there's no updates etc. for the restored applications (someone confirm?)

"recover android market links" would be a nice feature :)
 

treyweez11

Senior Member
Jan 4, 2012
1,058
152
0
Atlanta
im sort of a newbie when it comes o scripts like this. I am running OSX Lion 10.7,5 and i have adb setup. Can i use this? Shiiiid how do i use this??


NVM: Too much work
 
Last edited:

wizwin

Senior Member
Nov 22, 2010
192
212
73
Bangalore
www.winnyonnet.ml
Please note: This apparently currently breaks android market links
I used titanium backup pro to restore them

Without, i guess there's no updates etc. for the restored applications (someone confirm?)

"recover android market links" would be a nice feature :)
I have seen/used this feature in TB, let me check if something needs to be done to provide this feature.

hy!how can I use in windows 7 32 bit??
Yes! you can run it on any Desktop OS with Perl installed.

im sort of a newbie when it comes o scripts like this. I am running OSX Lion 10.7,5 and i have adb setup. Can i use this? Shiiiid how do i use this??

NVM: Too much work
Open a Terminal on Mac, change the directory to the path where you placed the 'AndSync.pl' script and type in 'perl AndSync.pl'. I have executed it on a Mac but not tested it completely but I guess it would work fine if you have setup Perl and adb.