Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
157 lines (133 sloc) 4.83 KB
buildscript {
repositories {
mavenLocal()
maven { url "https://plugins.gradle.org/m2/" }
jcenter()
}
dependencies {
classpath 'com.github.erizo.gradle:jcstress-gradle-plugin:0.8.3'
classpath 'net.ltgt.gradle:gradle-errorprone-plugin:1.1.0'
classpath "me.champeau.gradle:jmh-gradle-plugin:0.5.0"
classpath "gradle.plugin.com.github.sherter.google-java-format:google-java-format-gradle-plugin:0.8"
}
}
subprojects {
apply plugin: "checkstyle"
apply plugin: "java"
apply plugin: 'maven-publish'
apply plugin: "idea"
apply plugin: "jacoco"
apply plugin: "signing"
apply plugin: "me.champeau.gradle.jmh"
apply plugin: "net.ltgt.errorprone"
apply plugin: "com.github.sherter.google-java-format"
repositories {
maven {
url "https://maven-central.storage-download.googleapis.com/repos/central/data/" }
mavenLocal()
}
task javadocJar(type: Jar) {
classifier = 'javadoc'
from javadoc
}
task sourcesJar(type: Jar) {
classifier = 'sources'
from sourceSets.main.allSource
}
checkstyle {
configDir = file("$rootDir/buildscripts")
toolVersion = "6.17"
ignoreFailures = false
if (rootProject.hasProperty("checkstyle.ignoreFailures")) {
ignoreFailures = rootProject.properties["checkstyle.ignoreFailures"].toBoolean()
}
}
publishing {
publications {
maven(MavenPublication) {
from components.java
artifact javadocJar
artifact sourcesJar
pom {
name = project.group + ":" + project.name
url = 'https://github.com/perfmark/perfmark'
afterEvaluate {
// description is not available until evaluated.
description = project.description
}
scm {
connection = 'scm:git:https://github.com/perfmark/perfmark.git'
developerConnection = 'scm:git@github.com:perfmark/perfmark.git'
url = 'https://github.com/perfmark/perfmark'
}
licenses {
license {
name = 'Apache 2.0'
url = 'https://opensource.org/licenses/Apache-2.0'
}
}
developers {
developer {
id = "carl-mastrangelo"
name = "Carl Mastrangelo"
email = "carl@carlmastrangelo.com"
url = "https://www.perfmark.io/"
}
}
}
}
}
repositories {
maven {
def stagingUrl = 'https://oss.sonatype.org/service/local/staging/deploy/maven2/'
def releaseUrl = stagingUrl
def snapshotUrl = 'https://oss.sonatype.org/content/repositories/snapshots/'
url = version.endsWith('SNAPSHOT') ? snapshotUrl : releaseUrl
credentials {
if (rootProject.hasProperty('ossrhUsername')
&& rootProject.hasProperty('ossrhPassword')) {
username = rootProject.ossrhUsername
password = rootProject.ossrhPassword
}
}
}
mavenLocal()
}
}
signing {
required false
sign publishing.publications.maven
}
[publishMavenPublicationToMavenRepository, publishMavenPublicationToMavenLocal]*.onlyIf {
!name.contains("perfmark-agent") && !name.contains("perfmark-util")
}
if (rootProject.properties.get('errorProne', true)) {
dependencies {
errorprone 'com.google.errorprone:error_prone_core:2.3.3'
errorproneJavac 'com.google.errorprone:javac:9+181-r4173-1'
}
} else {
// Disable Error Prone
allprojects {
afterEvaluate { project ->
project.tasks.withType(JavaCompile) {
options.errorprone.enabled = false
}
}
}
}
jacoco { toolVersion = "0.8.2" }
group = "io.perfmark"
version = "0.21.0-SNAPSHOT"
ext {
libraries = [
errorprone: 'com.google.errorprone:error_prone_annotations:2.3.3',
jsr305: 'com.google.code.findbugs:jsr305:3.0.2',
gson: 'com.google.code.gson:gson:2.8.6',
truth: 'com.google.truth:truth:1.0'
]
}
dependencies {
testCompile group: 'junit', name: 'junit', version: '4.12'
}
}
You can’t perform that action at this time.