adb shell pm uninstall -k --user 0 <package-name>
adb shell cmd package install-existing <package-name>
Thanks, I know this is an option, but I prefer to avoid spending hours on reconfiguring my phone if I can, especially since there's no bug yet from having com.android.storagemanager uninstalled.
pm dump com.android.fmradio | grep path
pm install -r --user 0 /system/priv-app/FMRadio/FMRadio.apk
big brain ! i was looking this way since i accidentally disabled an app. this helped android 10 thank you !A lot of people searched for a way to uninstall bloat or APKs using ADB because a lot of OEMs don't allow uninstalling many of preinstalled apps.
Tested on Pie and Oreo.
BUT most of the articles if not all of them ( couldn't find any article saying otherwise ) say that after using the command "adb shell pm uninstall -k --user 0 <name of package here>" to uninstall an app, you have to factory reset your phone to get these packages back which Is NOT TRUE.
you can simply use "adb shell cmd package install-existing <package name>" in ADB and you'll get the package back .
Examples:-
adb shell pm uninstall -k --user 0 com.android.something
adb shell cmd package install-existing com.android.something
Tested and working on Android pie and Oreo on Samsung devices.
Seems like some people can't get it to work with no helpful information so we can't help much.
That's because you've entered the wrong command. If you're using command prompt then you don't have to type adb shell anymore. You just have to type cmd package install-existing <package name> then hit enter.
Sorry for the late reply, did you fix it yet? There was another command shared here.I actidently uninstall "adb shell pm uninstall -k --user 0 com.android.shell"
I copied the wrong one overlooking. I no longer have shell on my phone.
Andoid 11, oneUI 3.1
can anyone help?
Edit:
I have the shell.apk package, I pulled from another s10+ same phone and same OS version.
I install the apk by MIX Explorer to package installer. But it says app not installed.
I actidently uninstall "adb shell pm uninstall -k --user 0 com.android.shell"
I copied the wrong one overlooking. I no longer have shell on my phone.
Andoid 11, oneUI 3.1
can anyone help?
Edit:
I have the shell.apk package, I pulled from another s10+ same phone and same OS version.
I install the apk by MIX Explorer to package installer. But it says app not installed.
Failure [INSTALL_FAILED_INVALID_APK: Package com.android.systemui is a persistent app. Persistent apps are not updateable.]You can reinstall an uninstalled app like this (no need for factory reset):
get the path for that app (that's the same awk does, in my case I want FM-Radio back):
Code:pm dump com.android.fmradio | grep path
install the app:
Code:pm install -r --user 0 /system/priv-app/FMRadio/FMRadio.apk
"cmd package install-existing com.android.fmradio" did not work on my LOS 14.1, because the parameter "install-existing" seems not to be implemented.
pm dump com.android.fmradio | grep path
pm install -r --user 0 /system/priv-app/FMRadio/FMRadio.apk
I actidently uninstall "adb shell pm uninstall -k --user 0 com.android.shell"
I copied the wrong one overlooking. I no longer have shell on my phone.
Andoid 11, oneUI 3.1
can anyone help?
Edit:
I have the shell.apk package, I pulled from another s10+ same phone and same OS version.
I install the apk by MIX Explorer to package installer. But it says app not installed.