Skip to content
Permalink
Browse files

[JENKINS-8383] record fingerprints of ancestor poms

Originally-Committed-As: 5d202a2b9902082e9a44a2e0f5834e941b2c36dc
  • Loading branch information
Stephan Pauxberger
Stephan Pauxberger committed Sep 3, 2011
1 parent b16ba49 commit 7468a99eb37b75ad20d3937c0e57fe40703c44ae
Showing with 9 additions and 1 deletion.
  1. +9 −1 src/main/java/hudson/maven/reporters/MavenFingerprinter.java
@@ -81,7 +81,15 @@ public boolean preBuild(MavenBuildProxy build, MavenProject pom, BuildListener l
* Mojos perform different dependency resolution, so we need to check this for each mojo.
*/
public boolean postExecute(MavenBuildProxy build, MavenProject pom, MojoInfo mojo, BuildListener listener, Throwable error) throws InterruptedException, IOException {
record(pom.getArtifacts(),used);
MavenProject parent = pom.getParent();
while (parent != null) {
// Parent Artifact contains no acual file, so we resolve against the local repository
Artifact parentArtifact = parent.getProjectBuildingRequest().getLocalRepository().find(parent.getArtifact());
record(parentArtifact, used);
parent = parent.getParent();
}

record(pom.getArtifacts(),used);
record(pom.getArtifact(),produced);
record(pom.getAttachedArtifacts(),produced);
record(pom.getGroupId(),pom.getFile(),produced);

0 comments on commit 7468a99

Please sign in to comment.
You can’t perform that action at this time.