Get Android phone settings with ADB

A useful debugging tool, especially if you have several emulators in various states like I do, is to list all the phone settings that are stored in Settings.System and Settings.Secure as well as their current values.

$ adb shell
#sqlite3 /data/data/com.android.providers.settings/databases/settings.db
sqlite> select * from system;
sqlite> select * from secure;

Settings that once were in System migrate to Secure as Android versions get released, so it is sometimes handy to know exactly what state the phone is in while you’re debugging on it.