From 0bc2b7a1a11c872b58c5890542ddbd7da2359e59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=90=8C=E6=96=B0=E6=9D=B0=E5=B0=91?= <52126790+1250422131@users.noreply.github.com> Date: Sun, 13 Aug 2023 23:50:07 +0800 Subject: [PATCH 1/3] Update README.md --- README.md | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 13866af..58106c5 100644 --- a/README.md +++ b/README.md @@ -33,14 +33,24 @@ maven { ``` ### 库的引入 - +由于项目使用了KSP,需要在脚本顶部添加KSP插件,在每个使用KSP的模块都需要哦。 +groovy ```groovy -implementation 'com.github.1250422131.DeepReCopy:core:' -ksp 'com.github.1250422131.DeepReCopy:compiler:' +plugins { + id 'com.google.devtools.ksp' version '1.9.0-1.0.11' +} + +implementation 'com.imcys.deeprecopy:core:' +ksp 'com.imcys.deeprecopy:compiler:' ``` +kts ```kotlin -implementation("com.github.1250422131.DeepReCopy:core:") -ksp("com.github.1250422131.DeepReCopy:compiler:") +plugins { + id("com.google.devtools.ksp") version "1.9.0-1.0.11" +} + +implementation("com.imcys.deeprecopy:core:") +ksp("com.imcys.deeprecopy:compiler:") ``` ## 为什么要深拷贝 From 538f29f3ebb44313c260b87bc012968bf613004c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=90=8C=E6=96=B0=E6=9D=B0=E5=B0=91?= <52126790+1250422131@users.noreply.github.com> Date: Sun, 13 Aug 2023 23:51:47 +0800 Subject: [PATCH 2/3] Update README.md --- README.md | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/README.md b/README.md index 58106c5..ef72d6c 100644 --- a/README.md +++ b/README.md @@ -15,23 +15,6 @@ DeepReCopy是针对Kotlin的Data类所开发的深度拷贝功能库,利用KSP ## 如何使用 -### 仓库引入 - -请在你的`settings.gradle.kts`中的`repositories`中添加下面的仓库。 -如果你是普通的gradle脚本,那么请用下面这个groovy版本 - -```groovy -maven { url 'https://jitpack.io' } -``` - -如果你是kts扩展脚本,那么可以使用kotlin版本 - -```kotlin -maven { - setUrl("https://jitpack.io") -} -``` - ### 库的引入 由于项目使用了KSP,需要在脚本顶部添加KSP插件,在每个使用KSP的模块都需要哦。 groovy From 6c0a29074eaef8022ecd3137530e5f54fa2fb3d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=90=8C=E6=96=B0=E6=9D=B0=E5=B0=91?= <52126790+1250422131@users.noreply.github.com> Date: Wed, 16 Aug 2023 10:01:01 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E4=B8=B4=E6=97=B6=E6=9B=B4=E6=8D=A2?= =?UTF-8?q?=E4=B8=BAjitpack=E5=AF=BC=E5=85=A5=E4=BE=9D=E8=B5=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Maven中央仓库打包意外,暂时使用jitpack仓库。 --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index ef72d6c..d216a69 100644 --- a/README.md +++ b/README.md @@ -32,8 +32,8 @@ plugins { id("com.google.devtools.ksp") version "1.9.0-1.0.11" } -implementation("com.imcys.deeprecopy:core:") -ksp("com.imcys.deeprecopy:compiler:") +implementation("com.github.1250422131.DeepReCopy:core:") +ksp("com.github.1250422131.DeepReCopy:compiler:") ``` ## 为什么要深拷贝 @@ -82,13 +82,13 @@ EnhancedData是用来增强Data类的,现阶段它只有对Data类进行扩展 我们看一则例子: - ```kotlin +```kotlin @EnhancedData data class AData(val name: String, val title: String, val bData: BData) @EnhancedData data class BData(val doc: String, val content: String) - ``` +``` 当对AData和BData顶上注解后我们点击Android Studio的Build。