cretin45 | d4cea55 | 2016-04-25 11:00:04 -0700 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | |
Michael Bestas | ec05005 | 2024-02-14 20:35:43 +0200 | [diff] [blame] | 3 | # SPDX-FileCopyrightText: 2017-2024 The LineageOS Project |
| 4 | # SPDX-License-Identifier: Apache-2.0 |
| 5 | |
cretin45 | d4cea55 | 2016-04-25 11:00:04 -0700 | [diff] [blame] | 6 | adb root |
| 7 | wait ${!} |
Michael W | 563a38c | 2022-03-20 13:42:50 +0100 | [diff] [blame] | 8 | has_google_suw=$(adb shell pm list packages com.google.android.setupwizard) |
Oliver Scott | 1db317b | 2024-01-10 16:30:37 -0500 | [diff] [blame] | 9 | adb shell pm enable org.lineageos.setupwizard/.FinishActivity || true |
Michael W | 563a38c | 2022-03-20 13:42:50 +0100 | [diff] [blame] | 10 | if [[ ! -z "$has_google_suw" ]] |
| 11 | then |
| 12 | wait ${!} |
Oliver Scott | 1db317b | 2024-01-10 16:30:37 -0500 | [diff] [blame] | 13 | adb shell pm enable com.google.android.setupwizard/.SetupWizardExitActivity || true |
Michael W | 563a38c | 2022-03-20 13:42:50 +0100 | [diff] [blame] | 14 | wait ${!} |
| 15 | fi |
cretin45 | d4cea55 | 2016-04-25 11:00:04 -0700 | [diff] [blame] | 16 | sleep 1 |
Oliver Scott | 1db317b | 2024-01-10 16:30:37 -0500 | [diff] [blame] | 17 | adb shell am start org.lineageos.setupwizard/.FinishActivity || true |
Michael W | 563a38c | 2022-03-20 13:42:50 +0100 | [diff] [blame] | 18 | if [[ ! -z "$has_google_suw" ]] |
| 19 | then |
| 20 | wait ${!} |
| 21 | sleep 1 |
Oliver Scott | 1db317b | 2024-01-10 16:30:37 -0500 | [diff] [blame] | 22 | adb shell am start com.google.android.setupwizard/.SetupWizardExitActivity |
Michael W | 563a38c | 2022-03-20 13:42:50 +0100 | [diff] [blame] | 23 | fi |