in src/main/java/org/apache/maven/plugins/dependency/utils/DependencyUtil.java [148:178]
public static File getFormattedOutputDirectory(
boolean useSubdirsPerScope,
boolean useSubdirsPerType,
boolean useSubdirPerArtifact,
boolean useRepositoryLayout,
boolean removeVersion,
boolean removeType,
File outputDirectory,
Artifact artifact) {
StringBuilder sb = new StringBuilder(128);
if (useRepositoryLayout) {
// group id
sb.append(artifact.getGroupId().replace('.', File.separatorChar)).append(File.separatorChar);
// artifact id
sb.append(artifact.getArtifactId()).append(File.separatorChar);
// version
sb.append(artifact.getBaseVersion()).append(File.separatorChar);
} else {
if (useSubdirsPerScope) {
sb.append(artifact.getScope()).append(File.separatorChar);
}
if (useSubdirsPerType) {
sb.append(artifact.getType()).append("s").append(File.separatorChar);
}
if (useSubdirPerArtifact) {
String artifactString = getDependencyId(artifact, removeVersion, removeType);
sb.append(artifactString).append(File.separatorChar);
}
}
return new File(outputDirectory, sb.toString());
}