Skip to content

Commit

Permalink
Respect attach flag for descriptor set goals
Browse files Browse the repository at this point in the history
Fixes #59
  • Loading branch information
sergei-ivanov committed May 13, 2019
1 parent e35aa69 commit 68c82a4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,10 @@ protected File getOutputDirectory() {
@Override
protected void doAttachGeneratedFiles() {
final File outputDirectory = getOutputDirectory();
final File descriptorSetFile = new File(getOutputDirectory(), descriptorSetFileName);
projectHelper.attachArtifact(project, "pb", classifier, descriptorSetFile);
if (attach) {
final File descriptorSetFile = new File(getOutputDirectory(), descriptorSetFileName);
projectHelper.attachArtifact(project, "pb", classifier, descriptorSetFile);
}
buildContext.refresh(outputDirectory);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,10 @@ protected File getOutputDirectory() {
@Override
protected void doAttachGeneratedFiles() {
final File outputDirectory = getOutputDirectory();
final File descriptorSetFile = new File(getOutputDirectory(), descriptorSetFileName);
projectHelper.attachArtifact(project, "test-pb", classifier, descriptorSetFile);
if (attach) {
final File descriptorSetFile = new File(getOutputDirectory(), descriptorSetFileName);
projectHelper.attachArtifact(project, "test-pb", classifier, descriptorSetFile);
}
buildContext.refresh(outputDirectory);
}
}

0 comments on commit 68c82a4

Please sign in to comment.