Skip to content

Commit

Permalink
Merge pull request #5400 from stbischof/fix_reporter_dircreate
Browse files Browse the repository at this point in the history
reporter - create dirs for exported file
  • Loading branch information
bjhargrave committed Oct 19, 2022
2 parents 1414370 + 0f44d75 commit 0f79b84
Showing 1 changed file with 3 additions and 0 deletions.
@@ -1,6 +1,7 @@
package aQute.bnd.maven.reporter.plugin;

import java.io.File;
import java.nio.file.Files;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
Expand Down Expand Up @@ -124,6 +125,8 @@ public void execute() throws MojoExecutionException, MojoFailureException {

for (Entry<String, Resource> result : reportResults.entrySet()) {
File file = new File(result.getKey());
Files.createDirectories(file.getParentFile()
.toPath());
try {
result.getValue()
.write(file);
Expand Down

0 comments on commit 0f79b84

Please sign in to comment.