报错:No such property: nexusUsername for class: org.gradle.api.publication.maven.internal.ant.DefaultGroovyMavenDeployer
有些文章说是出现了版本过低的问题,我这边遇到的问题,是在library中的build.gradle中出现了类似下面的一段代码:
**uploadArchives {
configuration = configurations.archives
repositories.mavenDeployer {
beforeDeployment { MavenDeployment deployment -> signing.signPom(deployment) }
repository(url: sonatypeRepoS) {
authentication(userName: sonatypeUsername,
password: sonatypePassword)
}
pom.groupId = project.ext.groupId
pom.artifactId = project.ext.artifactId
pom.version = project.ext.version
pom.project {
name ‘Android SpringIndicator’
packaging ‘aar’
description ‘A spring indicator like Morning Routine guide’
url ‘https://github.com/chenupt/SpringIndicator’
scm {
url ‘https://github.com/chenupt/SpringIndicator.git’
connection ‘scm:git:git://github.com/chenupt/SpringIndicator.git’
developerConnection ‘scm:git:git@github.com/chenupt/SpringIndicator.git’
}
licenses {
license {
name ‘The Apache Software License, Version 2.0’
url ‘http://www.apache.org/licenses/LICENSE-2.0.txt’
distribution ‘repo’
}
}
developers {
developer {
id ‘*’
name ‘*’
email ‘**@outlook.com’
}
}
}
}
}**
虽然可能不有代表性,但给需要的朋友,看看是否有类似的问题