diff --git a/watch/.gitignore b/watch/.gitignore index a4a956b..b33ab3f 100644 --- a/watch/.gitignore +++ b/watch/.gitignore @@ -3,3 +3,5 @@ build/ local.properties .idea/ *.iml +*.jks +*.keystore diff --git a/watch/app/build.gradle.kts b/watch/app/build.gradle.kts index 5c31c9b..ad65748 100644 --- a/watch/app/build.gradle.kts +++ b/watch/app/build.gradle.kts @@ -17,9 +17,15 @@ android { buildTypes { // 에뮬레이터에서 본 맥의 로컬 백엔드 (compose 포트 9810) debug { buildConfigField("String", "API_BASE", "\"http://10.0.2.2:9810\"") } - // ponytail: 운영 서버 배포 전이라 비워 둠. 배포하면 https 주소로 - release { buildConfigField("String", "API_BASE", "\"\"") } + // 운영 서버 https 주소는 -PNALSSIGAK_API_BASE=… 또는 ~/.gradle/gradle.properties 로 + release { + buildConfigField("String", "API_BASE", "\"${providers.gradleProperty("NALSSIGAK_API_BASE").getOrElse("")}\"") + isMinifyEnabled = true + isShrinkResources = true + } } + // 오픈소스 라이선스 전문을 앱에 같이 싣는다 (MIT·OFL 고지 조건) + sourceSets["main"].assets.directories.add("../licenses") buildFeatures { compose = true buildConfig = true diff --git a/watch/build.gradle.kts b/watch/build.gradle.kts index 12a7ab9..9cf18ac 100644 --- a/watch/build.gradle.kts +++ b/watch/build.gradle.kts @@ -2,3 +2,20 @@ plugins { id("com.android.application") version "9.4.1" apply false id("org.jetbrains.kotlin.plugin.compose") version "2.4.20" apply false } + +// 앱·스킨 공통 업로드 키. 키 파일·비밀번호는 저장소 밖 ~/.gradle/gradle.properties 에 둔다. +// 값이 없으면 서명 없는 릴리스가 나온다(Play 에 올릴 수 없음). +subprojects { + plugins.withId("com.android.application") { + extensions.configure { + val store = providers.gradleProperty("NALSSIGAK_STORE_FILE").orNull ?: return@configure + val upload = signingConfigs.create("upload") { + storeFile = file(store) + storePassword = providers.gradleProperty("NALSSIGAK_STORE_PASSWORD").get() + keyAlias = providers.gradleProperty("NALSSIGAK_KEY_ALIAS").get() + keyPassword = providers.gradleProperty("NALSSIGAK_KEY_PASSWORD").get() + } + buildTypes.getByName("release").signingConfig = upload + } + } +} diff --git a/watch/licenses/LICENSE-fluent-emoji.txt b/watch/licenses/LICENSE-fluent-emoji.txt index 4142304..fc6fd7f 100644 --- a/watch/licenses/LICENSE-fluent-emoji.txt +++ b/watch/licenses/LICENSE-fluent-emoji.txt @@ -1 +1,23 @@ 3D icons in this folder are from Microsoft Fluent Emoji (https://github.com/microsoft/fluentui-emoji), licensed under the MIT License. Copyright (c) Microsoft Corporation. + +MIT License + +Copyright (c) Microsoft Corporation. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/watch/watchface/build.gradle.kts b/watch/watchface/build.gradle.kts index 4de48b6..85b7ff9 100644 --- a/watch/watchface/build.gradle.kts +++ b/watch/watchface/build.gradle.kts @@ -16,4 +16,10 @@ android { versionCode = 1 versionName = "0.1" } + buildTypes.getByName("release") { + // 스킨 번들엔 dex 가 없어야 한다. R8 이 R 클래스까지 다 걷어내게 + isMinifyEnabled = true + // 스킨 XML 이 이름으로만 부르는 아이콘·글꼴을 안 쓰는 걸로 보고 지운다. 켜지 말 것 + isShrinkResources = false + } }