Skip to content

Commit f955351

Browse files
authored
Merge pull request #161 from 93Pd9s8Jt/patch-1
Run adb as user 0 for app list
2 parents 71c6f31 + 072a63a commit f955351

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

functions/backup_func.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,10 +104,10 @@ function backup_func() {
104104
mkdir -p backup-tmp/Apps
105105
if [ "$backup_apps" = "yes" ]; then
106106
cecho "Exporting apps."
107-
app_count=$(adb shell pm list packages -3 -f | wc -l)
107+
app_count=$(adb shell pm list packages -3 -f --user 0 | wc -l)
108108
apps_exported=0
109109

110-
for app in $(adb shell pm list packages -3 -f)
110+
for app in $(adb shell pm list packages -3 -f --user 0)
111111
# -f: see their associated file
112112
# -3: filter to only show third party packages
113113
do

0 commit comments

Comments
 (0)