my app uses accessibility permission and every time i run it i need to grant the permission manually , it is tedious, is there an option to grant my app this permission, by some command ,just for debug purposes? Thank you.
There is, although I'm not sure if you need to do it as the root user. Try this command.
adb shell settings put secure enabled_accessibility_services %accessibility:packagename/packagename.YourAccessibilityServiceName
Keep in mind that if you have applicationIdSuffix for your debug build this command becomes
adb shell settings put secure enabled_accessibility_services %accessibility:packagename.applicationIdSuffix/packagename.YourAccessibilityServiceName
You can read more about the other secure settings you can modify using shell commands here.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With