代码拉取完成,页面将自动刷新
buildscript {
ext.bouncycastleVersion = '1.54'
ext.jacksonVersion = '2.8.5'
ext.javapoetVersion = '1.7.0'
ext.jnr_unixsocketVersion = '0.15'
ext.okhttpVersion = '3.8.1'
ext.rxjavaVersion = '1.2.4'
ext.slf4jVersion = '1.7.25'
// test dependencies
ext.equalsverifierVersion = '2.1.7'
ext.junitVersion = '4.11'
ext.junitBenchmarkVersion = '0.7.2'
ext.logbackVersion = '1.2.3'
ext.mockitoVersion = '1.10.19'
repositories {
mavenCentral()
}
dependencies {
classpath 'io.codearte.gradle.nexus:gradle-nexus-staging-plugin:0.5.3'
classpath 'com.github.jengelman.gradle.plugins:shadow:1.2.4'
}
}
plugins {
id "com.jfrog.bintray" version "1.7.3"
}
apply plugin: 'java'
apply plugin: 'idea'
// should only be applied to the root project, see
// https://github.com/Codearte/gradle-nexus-staging-plugin#multi-project-build
apply plugin: 'io.codearte.nexus-staging'
apply plugin: 'jacoco'
description 'web3j base project'
allprojects {
sourceCompatibility = 1.8
targetCompatibility = 1.8
group 'org.web3j'
version '3.4.0'
apply plugin: 'java'
apply plugin: 'jacoco'
apply plugin: 'checkstyle'
repositories {
mavenCentral()
}
// We don't want any compiler warnings
compileJava {
options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation"
}
compileTestJava {
options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation"
}
javadoc {
options.encoding = 'UTF-8'
}
jacoco {
toolVersion = '0.7.7.201606060606' // See http://www.eclemma.org/jacoco/.
}
jacocoTestReport {
reports {
xml.enabled true
}
}
tasks.withType(Test) {
reports.html.destination = file("${reporting.baseDir}/${name}")
}
checkstyle {
toolVersion = "7.7"
configFile = file("${rootProject.projectDir}/config/checkstyle/checkstyle.xml")
}
}
subprojects {
apply plugin: 'java'
dependencies {
testCompile "junit:junit:$junitVersion",
"org.mockito:mockito-core:$mockitoVersion"
}
}
configure(subprojects.findAll {it.name != 'integration-tests'}) {
// Required for Maven Nexus repository
apply plugin: 'maven'
apply plugin: 'signing'
// Required for JFrog Artifactory repository
apply plugin: 'maven-publish'
apply plugin: 'com.jfrog.bintray'
task javadocJar(type: Jar) {
classifier = 'javadoc'
from javadoc
}
task sourcesJar(type: Jar) {
classifier = 'sources'
from sourceSets.main.allSource
}
task testJar(type: Jar) {
classifier = 'tests'
from sourceSets.test.output
}
artifacts {
archives sourcesJar, javadocJar, testJar
}
ext {
ossrhUsername = project.hasProperty('ossrhUsername') ? project.property('ossrhUsername') : ''
ossrhPassword = project.hasProperty('ossrhPassword') ? project.property('ossrhPassword') : ''
}
publishing {
publications {
mavenJava(MavenPublication) {
from components.java
artifact sourcesJar {
classifier 'sources'
}
artifact testJar {
classifier 'tests'
}
}
}
}
uploadArchives {
repositories {
mavenDeployer {
beforeDeployment { MavenDeployment deployment -> signing.signPom(deployment) }
repository(url: 'https://oss.sonatype.org/service/local/staging/deploy/maven2/') {
authentication(
userName: ossrhUsername,
password: ossrhPassword
)
}
pom.project {
name 'web3j'
packaging 'jar'
description project.description
url 'https://web3j.io'
scm {
connection 'scm:git:https://github.com/web3j/web3j.git'
url 'https://github.com/web3j/web3j.git'
}
licenses {
license {
name 'The Apache License, Version 2.0'
url 'http://www.apache.org/licenses/LICENSE-2.0.txt'
}
}
developers {
developer {
id 'conor10'
name 'Conor Svensson'
email 'conor10@gmail.com'
}
}
}
}
}
}
signing {
required { gradle.taskGraph.hasTask('uploadArchives') } // only execute as part of this task
sign configurations.archives
}
bintray {
user = project.hasProperty('bintrayUser') ? project.property('bintrayUser') : System.getenv('BINTRAY_USER')
key = project.hasProperty('bintrayApiKey') ? project.property('bintrayApiKey') : System.getenv('BINTRAY_API_KEY')
publications = ['mavenJava']
publish = true
pkg {
repo = 'maven'
name = 'org.web3j'
desc = project.description
userOrg = 'web3j'
licenses = ['Apache-2.0']
issueTrackerUrl = 'https://github.com/web3j/web3j/issues'
vcsUrl = 'https://github.com/web3j/web3j.git'
websiteUrl = 'https://web3j.io'
publicDownloadNumbers = true
}
}
task release {
//TODO run clean & closeAndPromoteRepository once
dependsOn 'build'
dependsOn 'uploadArchives'
dependsOn 'bintrayUpload'
tasks.findByName('uploadArchives').mustRunAfter 'build'
tasks.findByName('bintrayUpload').mustRunAfter 'build'
}
}
task jacocoRootTestReport(type: org.gradle.testing.jacoco.tasks.JacocoReport) {
dependsOn = subprojects.test
additionalSourceDirs = files(subprojects.sourceSets.main.allSource.srcDirs)
sourceDirectories = files(subprojects.sourceSets.main.allSource.srcDirs)
classDirectories = files(subprojects.sourceSets.main.output)
executionData = files(subprojects.jacocoTestReport.executionData)
reports {
xml.enabled = true
}
onlyIf = {
true
}
doFirst {
executionData = files(executionData.findAll {
it.exists()
})
}
afterEvaluate {
classDirectories = files(classDirectories.files.collect {
fileTree(dir: it,
exclude: [
'org/web3j/abi/datatypes/generated/**',
'org/web3j/tuples/generated/**',
'org/web3j/ens/contracts/generated/**'
])
})
}
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。