Skip to content

Commit

Permalink
[CHORE]#7 Kakao sdk 기본 설정 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
flash159483 committed Jul 15, 2024
1 parent 951d4e3 commit 05714e3
Show file tree
Hide file tree
Showing 7 changed files with 66 additions and 1 deletion.
15 changes: 15 additions & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
import org.jetbrains.kotlin.konan.properties.Properties


val properties = Properties()
properties.load(rootProject.file("local.properties").inputStream())

plugins {
alias(libs.plugins.wespot.android.application)
alias(libs.plugins.wespot.android.hilt)
Expand All @@ -10,6 +14,15 @@ plugins {
android {
namespace = "com.bff.wespot"

defaultConfig {
buildConfigField("String", "KAKAO_APP_KEY", properties.getProperty("KAKAO_APP_KEY"))
resValue(
"string",
"SCHEME_KAKAO_APP_KEY",
properties.getProperty("SCHEME_KAKAO_APP_KEY")
)
}

buildFeatures {
buildConfig = true
}
Expand All @@ -23,6 +36,8 @@ dependencies {
implementation(project(":core:ui"))
implementation(project(":core:common"))
implementation(project(":feature:auth"))

implementation(libs.kakao.sdk)
implementation(libs.androidx.appcompat)
implementation(libs.androidx.lifecycle.runtime.ktx)
implementation(libs.androidx.core.ktx)
Expand Down
20 changes: 19 additions & 1 deletion app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools">
<uses-permission android:name="android.permission.INTERNET"/>

<uses-permission android:name="android.permission.INTERNET" />

<application
android:name=".application.WeSpotApplication"
android:allowBackup="true"
Expand All @@ -24,6 +26,22 @@
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>

<activity
android:name="com.kakao.sdk.auth.AuthCodeHandlerActivity"
android:launchMode="singleTask"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.VIEW" />

<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />

<data
android:host="oauth"
android:scheme="@string/SCHEME_KAKAO_APP_KEY" />
</intent-filter>
</activity>
</application>

</manifest>
11 changes: 11 additions & 0 deletions app/src/main/kotlin/com/bff/wespot/WeSpotApplication.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package com.bff.wespot

import android.app.Application
import com.kakao.sdk.common.KakaoSdk

class WeSpotApplication : Application() {
override fun onCreate() {
super.onCreate()
KakaoSdk.init(this, BuildConfig.KAKAO_APP_KEY)
}
}
6 changes: 6 additions & 0 deletions feature/auth/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ android {
}

dependencies {
implementation(project(":domain"))
implementation(project(":core:model"))
implementation(project(":core:ui"))
implementation(project(":designsystem"))

implementation(libs.kakao.sdk)
implementation(libs.bundles.androidx.compose)
implementation(libs.bundles.orbit)
implementation(libs.junit)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
package com.bff.wespot.auth

import androidx.compose.runtime.Composable

@Composable
fun AuthScreen() {

}
4 changes: 4 additions & 0 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ lottie = "6.4.1"
timber = "5.0.1"
datastore = "1.1.1"

kakao_sdk = "2.12.1"

[libraries]
android-build = { module = "com.android.tools.build:gradle", version.ref = "gradle-plugin" }
kotlin-gradle = { group = "org.jetbrains.kotlin", name = "kotlin-gradle-plugin", version.ref = "kotlin" }
Expand Down Expand Up @@ -109,6 +111,8 @@ timber = { module = "com.jakewharton.timber:timber", version.ref = "timber"}
detekt-plugin = { module = "io.gitlab.arturbosch.detekt:detekt-gradle-plugin", version.ref = "detekt" }
ktlint-plugin = { module = "org.jlleitschuh.gradle:ktlint-gradle", version.ref = "ktlint" }

kakao_sdk = { group = "com.kakao.sdk", name = "v2-user", version.ref = "kakao_sdk" }

[bundles]
androidx-compose = [
"androidx-activity-compose",
Expand Down
3 changes: 3 additions & 0 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ dependencyResolutionManagement {
repositories {
google()
mavenCentral()
maven {
url = uri("https://devrepo.kakao.com/nexus/content/groups/public/")
}
}
}

Expand Down

0 comments on commit 05714e3

Please sign in to comment.