1package soy.iko.opencode.data.model
3import androidx.compose.runtime.Immutable
6 * A saved opencode server connection. The [password] for HTTP Basic auth is resolved
7 * separately from EncryptedSharedPreferences and is null when not loaded/needed.
10data class ServerProfile(
14 val username: String? = null,
15 val password: String? = null,
16 val lastUsed: Long = 0,
17 // When true, the client upgrades a cleartext http:// URL to https:// so credentials and
18 // traffic are never sent over the wire in the clear for this server.
19 val requireHttps: Boolean = false,
20 // Optional OkHttp certificate pin(s) ("sha256/<base64>", whitespace/comma-separated for
21 // multiple) applied to this server's TLS connection for defense against a rogue CA.
22 val certPin: String? = null,
24 val hasAuth: Boolean get() = !username.isNullOrBlank()
26 val displayLabel: String get() = label.takeIf { it.isNotBlank() } ?: baseUrl
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list