androidadb

Get application version name using adb


Is there an easy way to get the version name of an application on an Android device using adb shell?

I found the application version number (not the version name) in /data/system/packages.xml.

It would be nice if there was a file that contained the Application Info.


Solution

  • adb shell dumpsys package my.package | grep versionName
    

    as mentioned by @david and @Jeremy Fishman. This will be much quicker than:

    adb shell dumpsys | grep -A18 "Package \[my.package\]"