A repository for android application module to detect if layout file contain non-existent views.
Add
ResMonitor
plugin in root build.gradle,and do not forget add maven { url 'https://jitpack.io' } too.
buildscript {
ext.resmonitor_version='0.1.1'
repositories {
maven { url 'https://jitpack.io' } //add this line
google()
mavenCentral()
jcenter()
}
dependencies {
classpath "com.github.emile2013:ResMonitor:$resmonitor_version" //add this line
}
}
allprojects {
repositories {
maven { url 'https://jitpack.io' } //add this line
google()
mavenCentral()
jcenter()
}
}
apply
com.github.emile2013.res-monitor
plugin in module build.gradle file
apply plugin: 'com.android.application'
apply plugin: 'com.github.emile2013.res-monitor' // add this line
./gradlew checkReleaseRes
something output on console like:
Execution failed for task ':app:checkReleaseRes'.
> java.lang.Exception: androidx.core.view.ViewPager not exist !! but declare at:
# Referenced at /ResMonitor/sample/app/src/main/res/layout/content_main.xml:11
This program uses aapt_rule.txt and javassist to handle functions, so must set minifyEnabled=true in build.gradle file.
ResMonitor is licensed under the BSD 3-Clause License.