Affects Version/s: 7.1.1 CE GA2
Fix Version/s: None
Component/s: Dev Tools > Gradle Plugins
Normally, bndtools would allow the use of variables to generate jars.
For instance, it is perfectly valid to use:
Given that gradle will create project variables and bndtools will use them to generate the metadata.
However, besides the fact that standard Gradle tasks work as expected, generating jars with metadata, Liferay's custom task called "deploy" will ignore variables and use the symbolic name as a literal, deploying jars with that variable in its name. Even though the built jar has the correct name.
Using Liferay's workspace, set the symbolicname to something with a variable, then deploy. The jar file is generated correctly inside the build director, but the symbolic name literal is used as name for deployment follow by the jar extension.
In gradle, one could have for a module build.gradle the following:
ext.groupName = 'tech.esystems.liferay.smartling'
and in the bnd file:
the file would be deployed as: