in src/main/java/org/apache/maven/buildcache/checksum/MavenProjectInput.java [571:603]
private Path getPathOrNull(String text) {
// small optimization to not probe not-paths
if (isBlank(text)) {
// do not even bother logging about blank/null values
} else if (equalsAnyIgnoreCase(text, "true", "false", "utf-8", "null", "\\") // common values
|| contains(text, "*") // tag value is a glob or regex - unclear how to process
|| (contains(text, ":") && !contains(text, ":\\")) // artifactId
|| startsWithAny(text, "com.", "org.", "io.", "java.", "javax.") // java packages
|| startsWithAny(text, "${env.") // env variables in maven notation
|| startsWithAny(
text,
"http:",
"https:",
"scm:",
"ssh:",
"git:",
"svn:",
"cp:",
"classpath:")) // urls identified by common protocols
{
LOGGER.debug("Skipping directory (blacklisted literal): {}", text);
} else if (startsWithAny(text, tmpDir)) // tmp dir
{
LOGGER.debug("Skipping directory (temp dir): {}", text);
} else {
try {
return Paths.get(text);
} catch (Exception ignore) {
LOGGER.debug("Skipping directory (invalid path): {}", text);
}
}
return null;
}