there is a command line to get package name:-
adb shell pm list packages
But how to get the list of all applications on the device
Previously the command for listing installed packages used to be pm list packages. But as of Android nougat, the command has been removed. The new command to do the same is cmd package list packages.
pm list packages
cmd package list packages
1.4m articles
1.4m replys
5 comments
57.0k users