Setting a string in APL.xml file
I am slowly trying to develop an android plugin and need some help about how you insert a variable into a string in the ___APL.xml file.
I am trying to add this permission
where $S(PackageName) is defined at the top as
can someone tell me the correct way i would get the variable to be replaced by the package name and not $S(PackageName).
asked Feb 12 '16 at 07:40 PM in Packaging & Deployment
Ok, a few things to look at here. Normally you'd use < addPermission /> for this, but it copies all the attributes exactly into a < use-permission /> tag if the name isn't already in the manifest. Since you want a string replacement this won't work, but there is another way to do this using element variables to make up the element.
The second issue is your way of getting the package name will work only if an exact package name is entered and doesn't use the [PROJECT] replacement. We can work around this as well by reading the package attribute from the manifest instead. This needs to be in the < androidManifestUpdates /> section, not < init />.
answered Feb 15 '16 at 06:36 PM
Chris Babcock STAFF
Follow this question
Once you sign in you will be able to subscribe for any updates here