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
15 changes: 10 additions & 5 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -22,28 +22,33 @@ android {

testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"

// 👇 공식 API + providers 사용
val localProps = gradleLocalProperties(rootDir, providers)

buildConfigField(
"String",
"NATIVE_APP_KEY",
gradleLocalProperties(rootDir).getProperty("native.app.key"),
"\"${localProps.getProperty("native.app.key")}\""
)
manifestPlaceholders["NATIVE_APP_KEY"] =
gradleLocalProperties(rootDir).getProperty("nativeAppKey")
// manifestPlaceholders는 문자열 그 자체를 넣으면 됨(따옴표 불필요)
manifestPlaceholders["NATIVE_APP_KEY"] = localProps.getProperty("nativeAppKey")
}
Comment on lines +31 to 35
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

속성 키 불일치 가능성 확인

buildConfigField"native.app.key" 값을, manifestPlaceholdersnativeAppKey 값을 사용하고 있습니다.
환경 파일에서 두 키가 모두 정의되지 않았을 경우 "null" 문자열이 삽입돼 런타임 크래시가 발생할 수 있으니 확인 부탁드립니다.
필요 시 check(localProps.getProperty(... ) != null)로 빌드 단계에서 조기 실패를 유도하는 것을 권장합니다.

🤖 Prompt for AI Agents
In app/build.gradle.kts around lines 31 to 35, there is a mismatch between the
property keys used: buildConfigField uses "native.app.key" while
manifestPlaceholders uses "nativeAppKey". To prevent runtime crashes from null
values if these keys are missing in localProps, add checks using
check(localProps.getProperty(...) != null) for both keys to fail early during
the build if either is undefined.


buildTypes {
debug {
val localProps = gradleLocalProperties(rootDir, providers)
buildConfigField(
"String",
"BASE_URL",
gradleLocalProperties(rootDir).getProperty("test.base.url")
"\"${localProps.getProperty("test.base.url")}\""
)
}
release {
val localProps = gradleLocalProperties(rootDir, providers)
buildConfigField(
"String",
"BASE_URL",
gradleLocalProperties(rootDir).getProperty("base.url")
"\"${localProps.getProperty("base.url")}\""
)
isMinifyEnabled = false
proguardFiles(
Expand Down
8 changes: 4 additions & 4 deletions buildSrc/src/main/kotlin/Constants.kt
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
object Constants {
const val packageName = "com.going.doorip"
const val compileSdk = 34
const val compileSdk = 35
const val minSdk = 28
const val targetSdk = 34
const val versionCode = 12
const val versionName = "1.2"
const val targetSdk = 35
const val versionCode = 14
const val versionName = "1.4"
}
98 changes: 63 additions & 35 deletions buildSrc/src/main/kotlin/Versions.kt
Original file line number Diff line number Diff line change
@@ -1,49 +1,77 @@
import org.gradle.api.JavaVersion

object Versions {
const val gradleVersion = "8.0.2"

const val buildToolsVersion = "30.0.3"
const val kotlinVersion = "1.8.20"
const val kotlinSerializationJsonVersion = "1.5.1"
const val kotlinDateTimeVersion = "0.4.0"
const val coreKtxVersion = "1.10.1"
const val appCompatVersion = "1.6.1"
const val materialDesignVersion = "1.9.0"
const val constraintLayoutVersion = "2.1.4"
// AGP (com.android.tools.build:gradle)
// plugins { id("com.android.application") version "8.7.2" } 로 맞춰 쓰는 걸 권장
const val gradleVersion = "8.7.2"

// buildToolsVersion는 AGP 8.x부터 명시 불필요. 그래도 상수 유지하려면 35로.
const val buildToolsVersion = "35.0.0"

// Kotlin
const val kotlinVersion = "1.9.24"
const val kotlinSerializationJsonVersion = "1.6.3"
const val kotlinDateTimeVersion = "0.6.1" // 최신권장

// AndroidX core / appcompat / material
const val coreKtxVersion = "1.13.1"
const val appCompatVersion = "1.7.0"
const val materialDesignVersion = "1.12.0"

// UI
const val constraintLayoutVersion = "2.1.4" // 2.2.0은 아직 안정화 대기
const val flexboxVersion = "3.0.0"
const val circleIndicatorVersion = "2.1.6"
const val circleImageViewVersion = "3.1.0"
const val shimmerVersion = "0.5.0"

// App Startup / Legacy / Security
const val appStartUpVersion = "1.1.1"
const val legacySupportVersion = "1.0.0"
const val securityVersion = "1.1.0-alpha06"
const val hiltVersion = "2.46.1"
const val activityKtxVersion = "1.7.2"
const val fragmentKtxVersion = "1.5.7"
const val coroutinesAndroidVersion = "1.7.1"
const val pagingVersion = "3.1.1"
const val lifecycleVersion = "2.6.1"
const val ossPluginVersion = "0.10.4"
const val ossVersion = "17.0.0"
const val securityVersion = "1.1.0-alpha06" // 안정판 대체 없으면 유지

// Hilt (Dagger)
const val hiltVersion = "2.51.1"

// Activity/Fragment/Lifecycle/Navi/Paging/Work/Splash
const val activityKtxVersion = "1.9.2"
const val fragmentKtxVersion = "1.8.3"
const val lifecycleVersion = "2.8.4"
const val navigationVersion = "2.8.0"
const val pagingVersion = "3.3.2"
const val workManagerVersion = "2.9.1"
const val splashVersion = "1.0.1"
const val workManagerVersion = "2.8.1"
const val coilVersion = "2.4.0"
const val retrofitVersion = "2.9.0"
const val kotlinSerializationConverterVersion = "1.0.0"
const val okHttpVersion = "4.11.0"

// Coroutines
const val coroutinesAndroidVersion = "1.9.0"

// Networking
const val retrofitVersion = "2.11.0"
const val kotlinSerializationConverterVersion = "1.0.0" // (JakeWharton) 최신 여전히 1.0.0
const val okHttpVersion = "4.12.0" // OkHttp 5는 API 변화 큼 → 4.12 권장

// 이미지/애니메이션
const val coilVersion = "2.6.0"
const val lottieVersion = "6.4.1"

// 기타
const val timberVersion = "5.0.1"
const val progressViewVersion = "1.1.3"
const val balloonVersion = "1.4.5"
const val lottieVersion = "6.0.0"
const val circularProgressBar = "3.1.0"
const val kakaoVersion = "2.19.0"
const val circleIndicatorVersion = "2.1.6"
const val shimmerVersion = "0.5.0"
const val navigationVersion = "2.6.0"
const val amplitudeVersion = "2.23.2"
const val amplitudeVersion = "2.23.2" // 프로젝트 요구 맞추되, 필요시 최신 확인

// 테스트
const val junitVersion = "4.13.2"
const val espressoVersion = "3.3.0"
const val androidTestVersion = "1.1.2"
const val flexboxVersion = "3.0.0"
const val circleImageViewVersion = "3.1.0"
const val espressoVersion = "3.6.1"
const val androidTestVersion = "1.2.1" // androidx.test:runner / rules 세트 기준

// Java / JVM
val javaVersion = JavaVersion.VERSION_21
const val jvmVersion = "21"

Comment on lines +70 to 73
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Java 21 전환 시 Toolchain 세팅 필수

JavaVersion.VERSION_21jvmTarget = "21"로 올리면

  1. AGP 8.x는 기본적으로 JDK 17로 빌드되므로, java { toolchain.languageVersion.set(JavaLanguageVersion.of(21)) } 설정이 필요하고
  2. 일부 라이브러리가 21 바이트코드를 지원하지 않을 수 있습니다.

CI, Gradle wrapper JVM, 릴리스 빌드가 모두 JDK 21로 통일돼 있는지 반드시 검증해주세요.

🤖 Prompt for AI Agents
In buildSrc/src/main/kotlin/Versions.kt around lines 70 to 73, when upgrading to
Java 21 by setting JavaVersion.VERSION_21 and jvmTarget to "21", you must
configure the Java toolchain explicitly using java {
toolchain.languageVersion.set(JavaLanguageVersion.of(21)) } to ensure AGP 8.x
builds with JDK 21 instead of the default JDK 17. Additionally, verify that the
CI environment, Gradle wrapper JVM, and release builds are all consistently
using JDK 21 to avoid compatibility issues with libraries that may not support
Java 21 bytecode.

val javaVersion = JavaVersion.VERSION_17
const val jvmVersion = "17"
// ▷ OSS Licenses
const val ossPluginVersion = "0.10.6"
const val ossVersion = "17.1.0"
}
2 changes: 1 addition & 1 deletion data/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ dependencies {
ThirdPartyDependencies.run {
implementation(retrofit)
implementation(okHttp)
implementation(okHttpBom)
implementation(platform(okHttpBom))
implementation(okHttpLoggingInterceptor)
implementation(retrofitJsonConverter)
implementation(timber)
Expand Down
3 changes: 1 addition & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#Fri Dec 29 23:45:17 KST 2023
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.0-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists