This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Parallelizing a fixed number range of long running actions | |
IntStream.range(0, NUM_OBJECTS_TO_CREATE).parallel().forEach(i -> { | |
//Your long running stuff goes here | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#List all remote branches merged to master | |
git branch -r --merged | |
#For all old branches log last commit e.g. | |
git log --decorate -1 origin/Gauss | |
#To delete the branches you want | |
git push origin --delete Gauss | |
#For everyone to run locally to remove the remove references |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
android.libraryVariants.all { variant -> | |
def name = variant.buildType.name | |
if (name.equals(com.android.builder.BuilderConstants.DEBUG)) { | |
return; // Skip debug builds. | |
} | |
def task = project.tasks.create "jar${name.capitalize()}", Jar | |
task.dependsOn variant.javaCompile | |
//Include Java classes | |
task.from variant.javaCompile.destinationDir | |
//Include dependent jars with some exceptions |