1 Star 35 Fork 4

yandeqing / ZRefreshView

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
maven_publish.gradle 2.85 KB
一键复制 编辑 原始数据 按行查看 历史
yandeqing 提交于 2021-09-01 17:59 . 文档更新
apply plugin: 'maven-publish'
apply plugin: 'signing'
//发布地址 https://s01.oss.sonatype.org/#stagingProfiles
afterEvaluate {
publishing {
def signingConfigPropsFile = rootProject.file("local.properties")
def signingConfigProps = new Properties()
signingConfigProps.load((new FileInputStream(signingConfigPropsFile)))
publications {
release(MavenPublication) {
from components.release
groupId = 'io.gitee.yandeqing' //sonatype平台创建的groupId 具体需要在https://issues.sonatype.org/projects上申请
artifactId = project.name
version = '1.0.3' //库版本名
project.ext["signing.keyId"] =signingConfigProps['signing.keyId'] //GPG指纹后8位
project.ext["signing.password"] = signingConfigProps['signing.password'] //GPG密码
project.ext["signing.secretKeyRingFile"] =signingConfigProps['signing.secretKeyRingFile'] //GPG私钥
pom {
name = "zrefreshview"
description = "add enableRefresh switch function"
url = "https://www.gitee.com/yandeqing" //github主页地址
licenses {
license {
name = "The Apache License, Version 2.0"
url = "http://www.apache.org/licenses/LICENSE-2.0.txt"
}
}
developers {
developer { //填开发者信息
id = "yandeqing"
name = "yandeqing"
email = "546218945@qq.com"
}
}
scm {
connection = "scm:svn:https://www.gitee.com/yandeqing" //后面为github主页地址
developerConnection = "scm:svn:https://www.gitee.com/yandeqing" //后面为github主页地址
url = "https://www.gitee.com/yandeqing" //github主页地址
}
}
}
}
repositories {
maven {
// release https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/ //正式上传地址
name = 'sonatypeRepository'
// url = "https://s01.oss.sonatype.org/content/repositories/snapshots/" //快照上传地址
url = "https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/"
credentials {
//sonatype平台账号密码
username = signingConfigProps["ossrhUsername"]
password = signingConfigProps["ossrhPassword"]
}
}
}
}
project.signing {
sign project.publishing.publications
}
}
Java
1
https://gitee.com/yandeqing/ZRefreshView.git
git@gitee.com:yandeqing/ZRefreshView.git
yandeqing
ZRefreshView
ZRefreshView
master

搜索帮助