diff options
author | Christopher Tate <ctate@google.com> | 2014-06-24 16:28:48 -0700 |
---|---|---|
committer | Christopher Tate <ctate@google.com> | 2014-06-24 16:52:09 -0700 |
commit | ab225b301b8b13a141053a33d5dd5eeccfc69887 (patch) | |
tree | e79e890866f6002fb9656ade335cc6bd4b31d812 /cmds | |
parent | 7218e9c6beaa066237c6b2aac6d10dd7dc84e0a2 (diff) | |
download | frameworks_base-ab225b301b8b13a141053a33d5dd5eeccfc69887.zip frameworks_base-ab225b301b8b13a141053a33d5dd5eeccfc69887.tar.gz frameworks_base-ab225b301b8b13a141053a33d5dd5eeccfc69887.tar.bz2 |
Add 'fullbackup' to bmgr's usage statement
Also make it handle the list of packages to be backed up as a single
multiple-app argument to fullTransportBackup() rather than N calls
each backing up one app.
Change-Id: I9fe4d5caca54fafef70ffe9af4c26e3941dc5d26
Diffstat (limited to 'cmds')
-rw-r--r-- | cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java b/cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java index d1bea2e..d683851 100644 --- a/cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java +++ b/cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java @@ -175,10 +175,13 @@ public final class Bmgr { System.out.println("Performing full transport backup"); String pkg; + ArrayList<String> allPkgs = new ArrayList<String>(); while ((pkg = nextArg()) != null) { - System.out.println(" Package " + pkg + " ..."); + allPkgs.add(pkg); + } + if (allPkgs.size() > 0) { try { - mBmgr.fullTransportBackup(new String[] { pkg }); + mBmgr.fullTransportBackup(allPkgs.toArray(new String[allPkgs.size()])); } catch (RemoteException e) { System.err.println(e.toString()); System.err.println(BMGR_NOT_RUNNING_ERR); @@ -474,6 +477,7 @@ public final class Bmgr { System.err.println(" bmgr restore PACKAGE"); System.err.println(" bmgr run"); System.err.println(" bmgr wipe TRANSPORT PACKAGE"); + System.err.println(" bmgr fullbackup PACKAGE..."); System.err.println(""); System.err.println("The 'backup' command schedules a backup pass for the named package."); System.err.println("Note that the backup pass will effectively be a no-op if the package"); @@ -489,11 +493,11 @@ public final class Bmgr { System.err.println(""); System.err.println("The 'list transports' command reports the names of the backup transports"); System.err.println("currently available on the device. These names can be passed as arguments"); - System.err.println("to the 'transport' and 'wipe' commands. The currently selected transport"); + System.err.println("to the 'transport' and 'wipe' commands. The currently active transport"); System.err.println("is indicated with a '*' character."); System.err.println(""); System.err.println("The 'list sets' command reports the token and name of each restore set"); - System.err.println("available to the device via the current transport."); + System.err.println("available to the device via the currently active transport."); System.err.println(""); System.err.println("The 'transport' command designates the named transport as the currently"); System.err.println("active one. This setting is persistent across reboots."); @@ -521,5 +525,8 @@ public final class Bmgr { System.err.println("erased from the given transport's storage. The next backup operation"); System.err.println("that the given application performs will rewrite its entire data set."); System.err.println("Transport names to use here are those reported by 'list transports'."); + System.err.println(""); + System.err.println("The 'fullbackup' command induces a full-data stream backup for one or more"); + System.err.println("packages. The data is sent via the currently active transport."); } } |