Skip to content

Instantly share code, notes, and snippets.

View bblackbelt's full-sized avatar

bblackbelt

  • Share the meal
  • Berlin, Germany
View GitHub Profile
@dmytrodanylyk
dmytrodanylyk / description.md
Last active June 20, 2022 15:00
Where this dependency comes from?

Did you ever have android build failed​ issue because of dependency resolution?

… or you were curious where all these old rxjava dependencies come from?

You can pretty easy track the module causing issues via following gradle command.

gradlew :root-module:dependencyInsight \
--configuration debugRuntimeClasspath \ // or debugCompileClasspath
--dependency io.reactivex:rxjava:1.1.0 > dependencies.txt // saves result to 'dependencies.txt' file
@WarrenFaith
WarrenFaith / build.gradle
Last active March 11, 2019 11:33
Basic script setup to add tasks like "testDebugUnitTestCoverage" (when you have no flavors defined) or "testFlavorNameDebugUnitTestCoverage" (replace FlavorName with your flavor name). Limitation: Does not work with flavor dimensions!
// in your root gradle file:
buildscript {
repositories {
jcenter()
google()
mavenCentral()
}
dependencies {
classpath "org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:2.6.1"
}
@Faheetah
Faheetah / Jenkinsfile.groovy
Last active March 6, 2024 18:14
Jenkinsfile idiosynchrasies with escaping and quotes
node {
echo 'Results included as an inline comment exactly how they are returned as of Jenkins 2.121, with $BUILD_NUMBER = 1'
echo 'No quotes, pipeline command in single quotes'
sh 'echo $BUILD_NUMBER' // 1
echo 'Double quotes are silently dropped'
sh 'echo "$BUILD_NUMBER"' // 1
echo 'Even escaped with a single backslash they are dropped'
sh 'echo \"$BUILD_NUMBER\"' // 1
echo 'Using two backslashes, the quotes are preserved'
sh 'echo \\"$BUILD_NUMBER\\"' // "1"