I'm working on publishing a revised version of my notification reminder profiles on the Wiki, and have decided that things need to be a little more user friendly. Although the notifications the profiles monitor are stock Google apps, and should have a should have the same package name on (almost) all devices, my (now dated) experience tells me that this isn't always the case; and varying package names will cause the profiles to not work as expected. Plus, being able to determine the package name will make it much easier for users to add other applications to the list of those being monitored. The reason I need the package name is that I'm using a script command
dumpsys notification to determine which notifications are present in the notification bar, which I then use to decide whether notification reminders should sound/vibrate.
I've looked at various events, actions and variables that might tell me the package name, but none seem to do/provide what I want. Specifically, I've looked at:
The
Notification event - I was hoping that %evtprm1 would give the package name, but instead if gives the app label (i.e. I want "
com.google.android.gm" and it gives "Gmail")
The Test action, using a Type of Package Name - given the package name, this returns the app label
If I could either get the Notification event to provide the package name, or something to do the opposite of what the Test Package Name action does, that would be perfect (I think). Any suggestions?