1 Star 0 Fork 0

郭艺宾/casbin-spring-boot-starter

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
maven.gradle 3.16 KB
一键复制 编辑 原始数据 按行查看 历史
fangzhengjin 提交于 2021-05-05 00:48 . semantic-release deploy
apply plugin: 'maven-publish'
apply plugin: 'signing'
apply plugin: 'io.github.gradle-nexus.publish-plugin'
ext {
ossrhUsername = findProperty("ossrhUsername") ?: System.getenv("OSSRH_USERNAME")
ossrhPassword = findProperty("ossrhPassword") ?: System.getenv("OSSRH_PASSWORD")
signingKey = findProperty("signingKey") ?: System.getenv("SIGNING_KEY")
signingPassword = findProperty("signingPassword") ?: System.getenv("SIGNING_PASSWORD")
}
task sourceJar(type: Jar) {
archiveClassifier = 'sources'
from sourceSets.main.allSource
}
javadoc {
options {
encoding "UTF-8"
charSet 'UTF-8'
// ignore custom tags
tags = [
"title:a:title",
"package:a:package",
"description:a:description",
"date:a:date"
]
}
}
task javadocJar(type: Jar, dependsOn: javadoc) {
archiveClassifier = 'javadoc'
from javadoc.destinationDir
}
publishing {
publications {
mavenJava(MavenPublication) {
// GAV configuration
from components.java
artifact sourceJar
artifact javadocJar
afterEvaluate {
groupId = GROUP
artifactId = ARTIFACT_ID
version = project.version
}
// resolve the dynamic dependency version into the actual reference version, e.g., 1.2.+ -> 1.2.10
versionMapping {
usage("java-api") {
fromResolutionOf("runtimeClasspath")
}
usage("java-runtime") {
fromResolutionResult()
}
}
// pom relative information
pom {
name = ARTIFACT_ID
description = POM_DESCRIPTION
url = POM_URL
scm {
url = POM_SCM_URL
connection = POM_SCM_CONNECTION
developerConnection = POM_SCM_DEV_CONNECTION
}
issueManagement {
system = 'Github'
url = ISSUE_URL
}
developers {
developer {
id = POM_DEVELOPER_ID
name = POM_DEVELOPER_NAME
email = POM_DEVELOPER_EMAIL
url = POM_DEVELOPER_URL
}
}
licenses {
license {
name = POM_LICENCE_NAME
url = POM_LICENCE_URL
distribution = POM_LICENCE_DIST
}
}
}
}
}
}
tasks.withType(GenerateMavenPom).all {
destination = "$buildDir/libs/${project.name}-${project.version}.pom"
}
build.dependsOn('sourceJar')
build.dependsOn('javadocJar')
build.dependsOn('generatePomFileForMavenJavaPublication')
signing {
useInMemoryPgpKeys(signingKey, signingPassword ?: "")
sign publishing.publications.mavenJava
}
nexusPublishing {
repositories {
sonatype {
username = ossrhUsername
password = ossrhPassword
}
}
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/blueses/casbin-spring-boot-starter.git
git@gitee.com:blueses/casbin-spring-boot-starter.git
blueses
casbin-spring-boot-starter
casbin-spring-boot-starter
master

搜索帮助