Skip to content

Instantly share code, notes, and snippets.

@Orange168
Last active August 10, 2016 09:55
Show Gist options
  • Save Orange168/c391645022c584c094e28135f4978838 to your computer and use it in GitHub Desktop.
Save Orange168/c391645022c584c094e28135f4978838 to your computer and use it in GitHub Desktop.
```
android {
buildTypes {
debug {
applicationIdSuffix ".debug"
}
jnidebug {
initWith(buildTypes.debug)
applicationIdSuffix ".jnidebug"
jniDebuggable true
}
}
}
android {
sourceSets.jnidebug.setRoot('foo/jnidebug')
}
```
`./gradlew :app:dependencies and ./gradlew :app:androidDependencies.`
#### Filtering Variants
```
android {
productFlavors {
realData
fakeData
}
variantFilter { variant ->
def names = variant.flavors*.name
if (names.contains("fakeData") && variant.buildType.name == "release") {
variant.ignore = true
}
}
}
```
android {
lintOptions {
// turn off checking the given issue id's
disable 'TypographyFractions','TypographyQuotes'
// turn on the given issue id's
enable 'RtlHardcoded','RtlCompat', 'RtlEnabled'
// check *only* the given issue id's
check 'NewApi', 'InlinedApi'
}
}
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment