Add signing support to gradle (via user.gradle configuratio file)
This commit is contained in:
parent
342a828cf8
commit
75bd6cedd0
|
@ -2,3 +2,4 @@
|
|||
gen
|
||||
bin
|
||||
build
|
||||
user.gradle
|
||||
|
|
22
build.gradle
22
build.gradle
|
@ -22,16 +22,18 @@ dependencies {
|
|||
|
||||
tasks.findByPath(':preBuild').dependsOn += ':compatSetup'
|
||||
|
||||
task compatSetup (dependsOn: [':compat:assembleDebug',':compat:assembleRelease']) << {
|
||||
task compatSetup(dependsOn: [':compat:assembleDebug', ':compat:assembleRelease']) << {
|
||||
final java.util.concurrent.atomic.AtomicBoolean classpathSet = new java.util.concurrent.atomic.AtomicBoolean(false);
|
||||
tasks.findAll{it.path.startsWith(':compile') && it.path.endsWith('Java')}.each{it.doFirst {
|
||||
if (!classpathSet.get()) {
|
||||
android.applicationVariants.all {
|
||||
variant -> variant.javaCompile.classpath += project(':compat').files('build/intermediates/bundles/' + (variant.name.endsWith('ebug') ? 'debug' : 'release') + '/classes.jar');
|
||||
};
|
||||
classpathSet.set(true);
|
||||
tasks.findAll { it.path.startsWith(':compile') && it.path.endsWith('Java') }.each {
|
||||
it.doFirst {
|
||||
if (!classpathSet.get()) {
|
||||
android.applicationVariants.all {
|
||||
variant -> variant.javaCompile.classpath += project(':compat').files('build/intermediates/bundles/' + (variant.name.endsWith('ebug') ? 'debug' : 'release') + '/classes.jar');
|
||||
};
|
||||
classpathSet.set(true);
|
||||
}
|
||||
}
|
||||
}};
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
|
@ -61,3 +63,7 @@ android {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (file('user.gradle').exists()) {
|
||||
apply from: 'user.gradle'
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue