-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* add clikt, build uber jar * graalvm no fallback * add test binary step in gh action
- Loading branch information
Showing
5 changed files
with
46 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,6 +14,13 @@ jobs: | |
with: | ||
java-version: '11' | ||
distribution: 'adopt' | ||
- name: Build Fat Jar | ||
uses: eskatos/[email protected] | ||
with: | ||
arguments: shadowJar | ||
wrapper-cache-enabled: true | ||
dependencies-cache-enabled: true | ||
configuration-cache-enabled: true | ||
- name: Build GraalVM Native Image | ||
uses: eskatos/[email protected] | ||
with: | ||
|
@@ -24,7 +31,9 @@ jobs: | |
- name: Release | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
files: build/graal/klisp | ||
files: | | ||
build/graal/klisp | ||
build/libs/klisp.jar | ||
draft: true | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import com.github.ajalt.clikt.core.CliktCommand | ||
import com.github.ajalt.clikt.parameters.options.option | ||
|
||
class Cli : CliktCommand() { | ||
private val expressionToEvaluate: String? by option("-e", "--evaluate", help = "evaluate expression") | ||
|
||
override fun run() { | ||
val env = DefaultEnv() | ||
expressionToEvaluate?.let { | ||
println(buildAst(it).evaluate(env)) | ||
return@run | ||
} | ||
|
||
repl() | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -51,4 +51,4 @@ fun repl() { | |
} | ||
} | ||
|
||
fun main() = repl() | ||
fun main(args: Array<String>) = Cli().main(args) |