Skip to content

Commit

Permalink
Updated Kotlin to 2.0.0 and Compose to 1.6.10
Browse files Browse the repository at this point in the history
  • Loading branch information
JetpackDuba committed May 22, 2024
1 parent 8f1f87f commit 0a324f1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
9 changes: 5 additions & 4 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@ val linuxX64Target = "x86_64-unknown-linux-gnu"

plugins {
// Kotlin version must match compose version
kotlin("jvm") version "1.9.20"
kotlin("plugin.serialization") version "1.9.20"
id("com.google.devtools.ksp") version "1.9.20-1.0.14"
id("org.jetbrains.compose") version "1.6.1"
kotlin("jvm") version "2.0.0"
kotlin("plugin.serialization") version "2.0.0"
id("com.google.devtools.ksp") version "2.0.0-1.0.21"
id("org.jetbrains.compose") version "1.6.10"
id("org.jetbrains.kotlin.plugin.compose") version "2.0.0"
}

// Remember to update Constants.APP_VERSION when changing this version
Expand Down
4 changes: 2 additions & 2 deletions src/main/kotlin/com/jetpackduba/gitnuro/ui/diff/Diff.kt
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ import java.io.FileInputStream
import kotlin.math.max

private const val MAX_MOVES_COUNT = 5

@Composable
private fun <T> loadOrNull(key: Any, action: suspend () -> T?): T? {
var result: T? by remember(key) { mutableStateOf(null) }
Expand Down Expand Up @@ -805,8 +806,7 @@ fun HunkHeader(
// Hunks options are only visible when repository is a normal state (not during merge/rebase)
if (
(diffEntryType is DiffEntryType.SafeStagedDiff || diffEntryType is DiffEntryType.SafeUnstagedDiff) &&
(diffEntryType is DiffEntryType.UncommittedDiff && // Added just to make smartcast work
diffEntryType.statusEntry.statusType == StatusType.MODIFIED)
diffEntryType.statusType == StatusType.MODIFIED
) {
val buttonText: String
val color: Color
Expand Down

0 comments on commit 0a324f1

Please sign in to comment.