Skip to content

dylanwatsonsoftware/bobatea

Repository files navigation

Boba Tea - Kotlin TUI

Boba Tea
Build Status JitPack Java

Download

repositories {
    mavenCentral()
    maven { url 'https://jitpack.io' }
}

dependencies {
    implementation 'com.github.dylanwatsonsoftware:bobatea:$version'
}

Examples

The full code for the examples can be viewed here

Loading


runLoading("Loading yo!") {
    Thread.sleep(10000)
}

Multi-select


val multiSelections = selectMultipleFromList(
    question = "What are all your favourite numbers?",
    options =
    listOf("one", "two", "three", "four", "five", "six", "seven", "eight", "nine", "ten"),
)
println("You selected: $multiSelections")

Single Select


val selection = selectFromList(
    question = "What's your favourite number?",
    options =
    listOf("one", "two", "three", "four", "five", "six", "seven", "eight", "nine", "ten"),
)
println("You selected: $selection")

Co-ordinate Selection

This simply shows how easy it easy to create custom navigation with the bobatea framework


View the code for this example here

Sample

To run the sample:

./gradlew -p sample fatJar
java -jar ./sample/build/libs/sample-0.1-standalone.jar

About

A TUI framework, written in Kotlin - inspired by the Go Framework Bubbletea

Resources

License

Stars

Watchers

Forks

Packages

No packages published