Skip to content

Commit

Permalink
fix: add lost language config for cli app
Browse files Browse the repository at this point in the history
  • Loading branch information
phodal committed Mar 24, 2022
1 parent 2d5a0e4 commit 990c7e7
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion chapi-application/src/main/kotlin/chapi/app/cli/Chapi.kt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package chapi.app.cli

import chapi.app.analyser.ChapiAnalyser
import chapi.app.analyser.TypeScriptAnalyserApp
import chapi.app.analyser.config.ChapiConfig
import chapi.app.frontend.ContainerService
import chapi.app.frontend.FrontendApiAnalyser
import com.github.ajalt.clikt.core.CliktCommand
Expand All @@ -14,9 +15,10 @@ import java.io.File

class Ast : CliktCommand() {
val path: String by option(help="the path to analysis").default(".")
val language: String by option(help="the path to analysis").default("java")

override fun run() {
val results = ChapiAnalyser().analysis(path)
val results = ChapiAnalyser(ChapiConfig(language)).analysis(path)
File("chapi.json").writeText(results.toList().toString())
}
}
Expand Down

0 comments on commit 990c7e7

Please # to comment.