Skip to content

Commit

Permalink
Add kotlin autoconfig (#551)
Browse files Browse the repository at this point in the history
  • Loading branch information
quantum5 authored Oct 11, 2019
1 parent aca6733 commit 24578e7
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions dmoj/executors/KOTLIN.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,15 @@ def get_compile_args(self):
@classmethod
def get_versionable_commands(cls):
return [('kotlinc', cls.get_compiler()), ('java', cls.get_vm())]

@classmethod
def autoconfig(cls):
kotlinc = cls.find_command_from_list(['kotlinc'])
if kotlinc is None:
return None, False, 'Failed to find "kotlinc"'

java = cls.find_command_from_list(['java'])
if java is None:
return None, False, 'Failed to find "java"'

return cls.autoconfig_run_test({cls.compiler: kotlinc, cls.vm: cls.unravel_java(java)})

0 comments on commit 24578e7

Please sign in to comment.