I'm setting shrinkResources to true as follows:
releasepro {
minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
applicationIdSuffix ".pro"
}
But this is removing only a few unused resources. I am aware that gradle does some guessing and leaves resources that is is not sure are unused. Is there a way to remove all unused resources 100% ?
I read about setting the shrinkMode to strict in another thread. Will that help? I could not try it as I could not figure where to set it. Looked for examples and documents but unfortunately could not get to the right page.
Is there a way to ensure 100% removal of unused resources?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…