@Override
public DirectoryProcessingResult detectRoots(@NotNull File dir, @NotNull File[] children, @NotNull File base, @NotNull List<DetectedProjectRoot> result) {
Pattern pattern = Pattern.compile(".*\\.[e|h]rl");
List<File> filesByMask = FileUtil.findFilesByMask(pattern, base);
if (!filesByMask.isEmpty()) {
result.add(new DetectedProjectRoot(dir) {
@NotNull
@Override
public String getRootTypeName() {
return "Erlang";
}