diff --git a/start_lineage_wizard.sh b/start_lineage_wizard.sh index 5ad5e793..09ab6d1f 100755 --- a/start_lineage_wizard.sh +++ b/start_lineage_wizard.sh @@ -2,8 +2,12 @@ adb root wait ${!} -adb shell pm disable com.google.android.setupwizard || true -wait ${!} -adb shell pm disable com.android.provision || true -wait ${!} +if adb shell pm list packages | grep com.google.android.setupwizard; then + adb shell pm disable com.google.android.setupwizard || true + wait ${!} +fi +if adb shell pm list packages | grep com.android.provision; then + adb shell pm disable com.android.provision || true + wait ${!} +fi adb shell am start org.lineageos.setupwizard/org.lineageos.setupwizard.SetupWizardTestActivity diff --git a/start_lineage_wizard_with_gms.sh b/start_lineage_wizard_with_gms.sh index 2e036257..11a533cd 100755 --- a/start_lineage_wizard_with_gms.sh +++ b/start_lineage_wizard_with_gms.sh @@ -4,8 +4,10 @@ adb root wait ${!} adb shell pm enable com.google.android.setupwizard || true wait ${!} -adb shell pm disable com.android.provision || true -wait ${!} +if adb shell pm list packages | grep com.android.provision; then + adb shell pm disable com.android.provision || true + wait ${!} +fi adb shell am start org.lineageos.setupwizard/org.lineageos.setupwizard.SetupWizardTestActivity wait ${!} sleep 1