fb83441e35
Useful for deriving a list of presigned apps.
13 lines
374 B
Bash
Executable file
13 lines
374 B
Bash
Executable file
#!/usr/bin/env bash
|
|
|
|
set -eufo pipefail
|
|
|
|
for pkg in $(adb shell pm list packages -s | sed 's/package://g')
|
|
do
|
|
out="$(adb shell dumpsys package $pkg)"
|
|
if grep -q "path: /data/app" <<< "$out"; then
|
|
#echo $pkg
|
|
sys_dir="$(grep codePath= <<< "$out" | cut -d'=' -f2 | grep -v /data | head -n1)"
|
|
adb shell ls $sys_dir/'*.apk' | head -n1
|
|
fi
|
|
done
|