Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The name of the "proguarded" JAR under target/ is different from the one installed under .m2. #108

Open
wheredevel opened this issue Mar 29, 2020 · 0 comments

Comments

@wheredevel
Copy link

wheredevel commented Mar 29, 2020

Here's the portion of the plugin configuration:

				<plugin>
					<groupId>com.github.wvengen</groupId>
					<artifactId>proguard-maven-plugin</artifactId>
					<version>${proguard-maven-plugin.version}</version>
					<configuration>
						<attach>true</attach>
						<attachArtifactClassifier>obfuscated</attachArtifactClassifier>
					...
					<configuration>
				</plugin>

Here's the portion of the plugin execution:

					<plugin>
						<groupId>com.github.wvengen</groupId>
						<artifactId>proguard-maven-plugin</artifactId>
						<executions>
							<execution>
								<phase>package</phase>
								<configuration>
									<injar>${project.build.finalName}-shaded.jar</injar>
								</configuration>
								<goals>
									<goal>proguard</goal>
								</goals>
							</execution>
						</executions>
					</plugin>

With the above configuration and execution, the resulting JAR name under target/ is:
xxxxxxx-shaded-obfuscated.jar

While the installed JAR (under .m2) name is:
xxxxxxx-obfuscated.jar

The expected behavior is that in both cases the name would be:
xxxxxxx-obfuscated.jar
(as it's based on the ${project.build.finalName} with an addition of attachArtifactClassifier value.)

So, the erroneous behavior is that the classifier is appended to the injar named file, instead of the project main artifact name.

Affected version of the plugin: 2.2.0. (Same happens also with 2.0.14.)

@wheredevel wheredevel changed the title The name of the "proguarded" JAR under target/ is different from the one installed. The name of the "proguarded" JAR under target/ is different from the one installed under .m2. Mar 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant