diff --git a/README.md b/README.md index 4c4a1b3..5010766 100644 --- a/README.md +++ b/README.md @@ -71,6 +71,7 @@ Options are optionally set in `options`, which is a semicolon-delimited list of - `e` prints the result of evaluating the code - `julia` Julia (Julia 1.1.0) - `e` prints the result of evaluating the code +- `kotlin` Kotlin (Kotlin 1.3) - `lua` Lua (Lua 5.3) - `pas` Pascal (FPC 3.0.4) - `php` PHP (PHP 7.3.3) diff --git a/docker/kotlin/Dockerfile b/docker/kotlin/Dockerfile new file mode 100644 index 0000000..cea9e98 --- /dev/null +++ b/docker/kotlin/Dockerfile @@ -0,0 +1,4 @@ +FROM kotlin:jdk12-alpine +LABEL author="1Computer1" + +COPY run.sh /var/run/ diff --git a/docker/kotlin/run.sh b/docker/kotlin/run.sh new file mode 100644 index 0000000..4c10111 --- /dev/null +++ b/docker/kotlin/run.sh @@ -0,0 +1,3 @@ +echo "$1" > program.kt +kotlinc program.kt -include-runtime -d program.jar +java -jar program.jar diff --git a/src/languages/kotlin.js b/src/languages/kotlin.js new file mode 100644 index 0000000..6a665f6 --- /dev/null +++ b/src/languages/kotlin.js @@ -0,0 +1,11 @@ +const Language = require('../struct/Language'); + +class Kotlin extends Language { + constructor() { + super('kotlin', { + aliases: ['kotlin'] + }); + } +} + +module.exports = Kotlin;