Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 11 additions & 12 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,20 @@

# Java class files
*.class
./.kotlin

# Kotlin
.kotlin

# Generated files
bin/
gen/
out/

# Gradle files
/.idea
.gradle/
build/
.cxx/


# Local configuration file (sdk path, etc)
local.properties
Expand All @@ -36,15 +39,13 @@ captures/

# Intellij
*.iml
.idea/workspace.xml
.idea/tasks.xml
.idea/gradle.xml
.idea/dictionaries
.idea/libraries
/.idea/*
!.idea/codeInsightSettings.xml
app/.idea/

# Mac
# DS_Store
*.DS_Store
**/DS_Store

# Keystore files
*.jks
Expand All @@ -55,7 +56,5 @@ app/.idea/
# Google Services (e.g. APIs or Firebase)
google-services.json

# Freeline
freeline.py
freeline/
freeline_project_description.json
# Temporary API docs
docs/api
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,11 @@ This library allows you to model your Retrofit responses with [Kotlin's Result](
[![Maven Central](https://img.shields.io/maven-central/v/com.github.skydoves/retrofit-adapters-result.svg?label=Maven%20Central)](https://search.maven.org/search?q=g:%22com.github.skydoves%22%20AND%20a:%22retrofit-adapters-result%22)
<br>

Add the dependency below to your **module**'s `build.gradle` file:
Add the dependency below to your **module**'s `build.gradle.kts` file:

```gradle
dependencies {
implementation "com.github.skydoves:retrofit-adapters-result:1.0.13"
implementation("com.github.skydoves:retrofit-adapters-result:1.0.13")
}
```

Expand Down
1 change: 0 additions & 1 deletion app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
*/
import com.skydoves.retrofit.adapters.Configuration

@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id(libs.plugins.android.application.get().pluginId)
id(libs.plugins.kotlin.android.get().pluginId)
Expand Down
17 changes: 11 additions & 6 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import org.jetbrains.kotlin.gradle.dsl.JvmTarget

// Designed and developed by 2022 skydoves (Jaewoong Eum)
//
// Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,7 +14,6 @@
// See the License for the specific language governing permissions and
// limitations under the License.

@Suppress("DSL_SCOPE_VIOLATION")
plugins {
alias(libs.plugins.android.application) apply false
alias(libs.plugins.android.library) apply false
Expand Down Expand Up @@ -57,11 +58,15 @@ subprojects {

if (!name.contains("app")) {
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().all {
kotlinOptions.jvmTarget = libs.versions.jvmTarget.get()
kotlinOptions.freeCompilerArgs += listOf(
"-Xopt-in=kotlinx.coroutines.ExperimentalCoroutinesApi",
"-Xexplicit-api=strict",
)
compilerOptions {
jvmTarget.set(JvmTarget.fromTarget(libs.versions.jvmTarget.get()))
freeCompilerArgs.addAll(
listOf(
"-Xopt-in=kotlinx.coroutines.ExperimentalCoroutinesApi",
"-Xexplicit-api=strict",
)
)
}
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
package com.skydoves.retrofit.adapters

object Configuration {
const val compileSdk = 34
const val targetSdk = 34
const val minSdk = 19
const val compileSdk = 36
const val targetSdk = 36
const val minSdk = 21
const val minSdkDemo = 21
const val majorVersion = 1
const val minorVersion = 0
Expand Down
34 changes: 17 additions & 17 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,34 +1,34 @@
[versions]
agp = "8.7.3"
kotlin = "2.1.10"
agp = "8.12.0"
kotlin = "2.2.10"
dokka = "2.0.0"
jvmTarget = "11"
nexusPlugin = "0.30.0"
binaryCompatibility = "0.17.0"
appcompat = "1.7.0"
nexusPlugin = "0.34.0"
binaryCompatibility = "0.18.1"
appcompat = "1.7.1"
material = "1.12.0"
retrofit = "2.11.0"
okhttp = "4.12.0"
coroutines = "1.10.1"
kotlinSerialization = "1.8.0"
arrow = "1.2.0"
paging = "3.3.5"
ksp = "2.1.0-1.0.29"
retrofit = "3.0.0"
okhttp = "5.1.0"
coroutines = "1.10.2"
kotlinSerialization = "1.9.0"
arrow = "2.1.2"
paging = "3.3.6"
ksp = "2.2.10-2.0.2"
moshi = "1.15.2"
glide = "4.16.0"
androidxLifecycle = "2.8.7"
androidxMacroBenchmark = "1.3.3"
androidxLifecycle = "2.9.2"
androidxMacroBenchmark = "1.4.0"
androidxProfileinstaller = "1.4.1"
androidxUiAutomator = "2.3.0"
junit = "4.13.2"
androidxTest = "1.6.2"
androidxJunit = "1.2.1"
androidxTest = "1.7.0"
androidxJunit = "1.3.0"
androidxArchTest = "2.1.0"
mockito = "5.14.2"
mockitoInline = "5.2.0"
mockitoKotlin = "2.2.0"
timber = "5.0.1"
turbine = "1.2.0"
turbine = "1.2.1"
spotless = "6.21.0"

[plugins]
Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#Sun Nov 03 16:21:12 KST 2024
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.9-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public suspend inline fun <A, B, C> Either<A, B>.foldSuspend(
* @param onRight Performs on the encapsulated value if this [Either] instance represents [Right].
*/
public suspend inline fun <A, B, C> Either<A, B>.onRightSuspend(
crossinline onRight: suspend suspend (B) -> C,
crossinline onRight: suspend (B) -> C,
): Either<A, B> = apply {
if (this is Right) {
onRight(value)
Expand All @@ -74,7 +74,7 @@ public suspend inline fun <A, B, C> Either<A, B>.onRightSuspend(
* @param onLeft Performs on the encapsulated value if this [Either] instance represents [Left].
*/
public suspend inline fun <A, B, C> Either<A, B>.onLeftSuspend(
crossinline onLeft: suspend suspend (A) -> C,
crossinline onLeft: suspend (A) -> C,
): Either<A, B> = apply {
if (this is Left) {
onLeft(value)
Expand Down
6 changes: 5 additions & 1 deletion retrofit-adapters-result/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,11 @@ mavenPublishing {
}

tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().all {
kotlinOptions.freeCompilerArgs += listOf("-Xopt-in=kotlin.contracts.ExperimentalContracts")
compilerOptions {
freeCompilerArgs.addAll(
listOf("-Xopt-in=kotlin.contracts.ExperimentalContracts")
)
}
}

dependencies {
Expand Down
Loading