summaryrefslogtreecommitdiff
path: root/desktop/build.gradle.kts
diff options
context:
space:
mode:
authorElizabeth Alexander Hunt <me@liz.coffee>2026-11-12 21:41:08 -0800
committerElizabeth Alexander Hunt <me@liz.coffee>2026-11-12 21:41:08 -0800
commit2a9a3126a4955dffc40bc04ab88a5ccdb3da77c9 (patch)
treeb19e42dde8eccf6c653495bd103db75e78b19201 /desktop/build.gradle.kts
parent3afb04de43726d71580b626e856c68b6ed79984e (diff)
downloadrookery-2a9a3126a4955dffc40bc04ab88a5ccdb3da77c9.tar.gz
rookery-2a9a3126a4955dffc40bc04ab88a5ccdb3da77c9.zip
GAN: never stall on lost packets; fix packaged Bluetooth runtime
Live testing on a GANicE3 (Gen4) showed a move held for 32 s and a deliberate disconnect once 16 moves backed up, both waiting on a move-history reply that never came (inherited from gan-web-bluetooth). - Retry history requests every 300 ms while stalled; after 1.5 s release held moves in order, flag the first with Move.afterGap, and request facelets so consumers can resync. Never disconnect over a backlog; a driver tick runs every 150 ms under a shared lock. - Bundle jdk.security.auth (and the other modules Compose suggests) in the packaged runtime: dbus-java needs it to authenticate to BlueZ. - `--cube monitor`: print facelets only on change, mark gaps, and accept r (reset to solved) / f (refresh) on stdin. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'desktop/build.gradle.kts')
-rw-r--r--desktop/build.gradle.kts7
1 files changed, 6 insertions, 1 deletions
diff --git a/desktop/build.gradle.kts b/desktop/build.gradle.kts
index d143c5f..e0fd832 100644
--- a/desktop/build.gradle.kts
+++ b/desktop/build.gradle.kts
@@ -19,6 +19,8 @@ compose.desktop {
mainClass = "coffee.liz.rookery.desktop.MainKt"
jvmArgs += listOf("-Xmx256m", "-XX:+UseSerialGC")
nativeDistributions {
+ // From `./gradlew :desktop:suggestRuntimeModules`; jdk.security.auth is needed by dbus-java (Bluetooth).
+ modules("java.instrument", "jdk.security.auth", "jdk.unsupported")
targetFormats(TargetFormat.AppImage, TargetFormat.Deb)
packageName = "rookery"
packageVersion = "0.1.0"
@@ -27,4 +29,7 @@ compose.desktop {
}
// `./gradlew :desktop:run --args="--import file.txt"` passes args through; env lets tests point at a scratch home.
-tasks.withType<JavaExec>().configureEach { environment.putAll(System.getenv().filterKeys { it.startsWith("XDG_") || it.startsWith("ROOKERY_") }) }
+tasks.withType<JavaExec>().configureEach {
+ environment.putAll(System.getenv().filterKeys { it.startsWith("XDG_") || it.startsWith("ROOKERY_") })
+ standardInput = System.`in` // so `--cube monitor` can take commands
+}