Skip to content

Commit

Permalink
Add basic support for Kotlin
Browse files Browse the repository at this point in the history
  • Loading branch information
h3xstream committed Jun 22, 2021
1 parent 0e2a021 commit 4dca3a9
Showing 1 changed file with 9 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
public final class IdeaUtilImpl {

private static final Set<String> SUPPORTED_FILE_TYPES_EXT = new THashSet<>(Arrays
.asList("java", "scala", "groovy", "gradle", "aj"));
.asList("java", "scala", "groovy", "gradle", "aj","kt"));
public static final Set<FileType> SUPPORTED_FILE_TYPES;

static {
Expand All @@ -82,6 +82,10 @@ public final class IdeaUtilImpl {
if (!(aspectJ instanceof UnknownFileType)) {
supported.add(aspectJ);
}
final FileType kotlin = FileTypeManager.getInstance().getFileTypeByExtension("KT");
if (!(kotlin instanceof UnknownFileType)) {
supported.add(kotlin);
}
SUPPORTED_FILE_TYPES = supported;
}

Expand All @@ -102,6 +106,10 @@ public final class IdeaUtilImpl {
if (aspectJ != null) {
supported.add(aspectJ);
}
final Language kotlin = Language.findLanguageByID("Kotlin");
if (kotlin != null) {
supported.add(kotlin);
}
SUPPORTED_LANGUAGES = supported;
}

Expand Down

0 comments on commit 4dca3a9

Please sign in to comment.