diff --git a/app/androidApp/src/main/kotlin/com/example/aiapp/SpawnScreen.kt b/app/androidApp/src/main/kotlin/com/example/aiapp/SpawnScreen.kt index ad9af15..b0cdab9 100644 --- a/app/androidApp/src/main/kotlin/com/example/aiapp/SpawnScreen.kt +++ b/app/androidApp/src/main/kotlin/com/example/aiapp/SpawnScreen.kt @@ -86,7 +86,7 @@ fun SpawnScreen( // Only the Claude CLI has models, a working directory, and permission // modes; keying the extra fields on the kind rather than the provider // name keeps a second Claude provider from needing anything here. - val isClaude = current?.kind == "claude-cli" + val isClaude = current?.kind == "claude_cli" Column(Modifier.fillMaxSize().verticalScroll(rememberScrollState()).padding(16.dp)) { Row(verticalAlignment = Alignment.CenterVertically, modifier = Modifier.fillMaxWidth()) { diff --git a/server/src/config.rs b/server/src/config.rs index 8a4391e..beb1a15 100644 --- a/server/src/config.rs +++ b/server/src/config.rs @@ -143,14 +143,13 @@ pub struct HostConfig { /// Which translator runs a session. A new one is a new driver behind the /// same trait -- never a branch in shared code. /// -/// The kebab-case spelling is the one the phone compares against -/// (`SpawnScreen.kt`), so it is the HTTP surface's, not a formatting -/// choice. The cost lands on the config file, where a hyphen is not an -/// identifier: RON writes and reads it as `kind: r#claude-cli`. Left that -/// way rather than renaming the variant, because the string is a contract -/// with whatever build is installed on the phone and the file is not. +/// Snake case, which is both Rust's and RON's: this is written into a +/// config a person edits by hand, and a hyphen is not a RON identifier, so +/// kebab case cost the file a `kind: r#claude-cli` escape to say a name +/// nobody would type that way. The same string is what the phone compares +/// against (`SpawnScreen.kt`), so the two move together. #[derive(Debug, Clone, Copy, PartialEq, Eq, Serialize, Deserialize)] -#[serde(rename_all = "kebab-case")] +#[serde(rename_all = "snake_case")] pub enum DriverKind { /// The phase-1 fake: echoes messages back as streamed events. Proves /// the pipe (spawn, SSE, transcript cursors, questions) with no AI