diff --git a/README.md b/README.md index e59ce04d..354704e3 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Android垃圾代码生成插件 -此插件用于做马甲包时,减小马甲包与主包的代码相似度,避免被OPPO、VIVO等应用市场识别为马甲包。 +此插件用于做马甲包时,减小马甲包与主包的代码相似度,避免被某些应用市场识别为马甲包。 ### 使用方法 @@ -11,12 +11,10 @@ buildscript { mavenCentral() } dependencies { - classpath "com.github.qq549631030:android-junk-code:1.1.0" + classpath "com.github.qq549631030:android-junk-code:1.1.1" } } ``` -**由于jcenter即将关闭后续版本将不再发布到jcenter,转为发布到mavenCentral,groupId从原来的"cn.hx.plugin"改为"com.github.qq549631030"** - app目录的build.gradle模块中: diff --git a/build.gradle b/build.gradle index 019468dc..66c897c0 100644 --- a/build.gradle +++ b/build.gradle @@ -9,7 +9,7 @@ buildscript { dependencies { classpath 'com.android.tools.build:gradle:4.2.1' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" - classpath "com.github.qq549631030:android-junk-code:1.1.0" + classpath "com.github.qq549631030:android-junk-code:1.1.1" classpath 'com.vanniktech:gradle-maven-publish-plugin:0.18.0' classpath "com.getkeepsafe.dexcount:dexcount-gradle-plugin:3.0.1" diff --git a/library/gradle.properties b/library/gradle.properties index 30b07531..3103d548 100644 --- a/library/gradle.properties +++ b/library/gradle.properties @@ -1,6 +1,6 @@ #project GROUP=com.github.qq549631030 -VERSION_NAME=1.1.0 +VERSION_NAME=1.1.1 POM_ARTIFACT_ID=android-junk-code POM_NAME=AndroidJunkCode diff --git a/library/src/main/groovy/cn/hx/plugin/junkcode/ext/AndroidJunkCodeExt.groovy b/library/src/main/groovy/cn/hx/plugin/junkcode/ext/AndroidJunkCodeExt.groovy index cbc6e744..e201cd23 100644 --- a/library/src/main/groovy/cn/hx/plugin/junkcode/ext/AndroidJunkCodeExt.groovy +++ b/library/src/main/groovy/cn/hx/plugin/junkcode/ext/AndroidJunkCodeExt.groovy @@ -1,9 +1,14 @@ package cn.hx.plugin.junkcode.ext +import org.gradle.api.Action import org.gradle.api.NamedDomainObjectContainer class AndroidJunkCodeExt { Map> configMap = [:] NamedDomainObjectContainer variantConfig + + void variantConfig(Action> action) { + action.execute(variantConfig) + } } \ No newline at end of file