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
project.extensions.create('foo', Foo) | |
foo { | |
project = ':project' | |
} | |
class Foo { | |
Project proj | |
void setProject(Project project) { |
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
apply plugin: 'war' | |
apply plugin: 'ear' | |
dependencies { | |
deploy files(war) | |
} |
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
include ':foo:common', ':bar:common' | |
gradle.rootProject { | |
project(':foo') { | |
subprojects { | |
apply plugin: 'idea' | |
} | |
} | |
project(':bar') { |
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
import org.gradle.api.Plugin | |
import org.gradle.api.Project | |
import org.gradle.api.internal.project.ProjectInternal | |
import org.gradle.caching.configuration.internal.BuildCacheConfigurationInternal | |
import org.gradle.caching.http.HttpBuildCache | |
class BuildCachePlugin implements Plugin<Project> { | |
@Override | |
void apply(Project project) { | |
def cacheConfig = ((ProjectInternal) project).services.get(BuildCacheConfigurationInternal) |
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
repositories { | |
jcenter() | |
} | |
configurations { | |
jars | |
} | |
dependencies { | |
jars 'junit:junit:4.12' |