Skip to content

Commit

Permalink
--amend
Browse files Browse the repository at this point in the history
  • Loading branch information
cescoffier committed Sep 26, 2023
1 parent 524543b commit e4c0502
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -286,8 +286,15 @@ private void extractProtosFromArtifact(Path workDir, Collection<Path> protoFiles
protoDirectories.add(path.getParent().normalize().toAbsolutePath().toString());
} else { // archive
Path relativePath = path.getRoot().relativize(path);
String uniqueName = artifact.getGroupId() + ":" + artifact.getArtifactId();
if (artifact.getVersion() != null) {
uniqueName += ":" + artifact.getVersion();
}
if (artifact.getClassifier() != null) {
uniqueName += "-" + artifact.getClassifier();
}
Path protoUnzipDir = workDir
.resolve(HashUtil.sha1(root.normalize().toAbsolutePath().toString()))
.resolve(HashUtil.sha1(uniqueName))
.normalize().toAbsolutePath();
try {
Files.createDirectories(protoUnzipDir);
Expand Down

0 comments on commit e4c0502

Please sign in to comment.