mirror of
https://gitee.com/BDWare/front-base
synced 2025-01-09 17:34:01 +00:00
add public support
This commit is contained in:
parent
27e47f4142
commit
912ecc21fc
82
build.gradle
82
build.gradle
@ -1,6 +1,8 @@
|
||||
plugins {
|
||||
id 'java'
|
||||
id 'java-library'
|
||||
id 'maven-publish'
|
||||
id 'signing'
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
@ -27,3 +29,83 @@ dependencies {
|
||||
api 'com.google.code.gson:gson:2.8.8'
|
||||
testImplementation 'junit:junit:4.13.2'
|
||||
}
|
||||
version = "1.0.0"
|
||||
task classJar(type: Jar, dependsOn: classes) {
|
||||
classifier = "jar"
|
||||
}
|
||||
task sourceJar(type: Jar, dependsOn: classes) {
|
||||
archiveClassifier = "sources"
|
||||
classifier = "sources"
|
||||
from sourceSets.main.allSource
|
||||
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
|
||||
}
|
||||
|
||||
tasks.withType(Javadoc) {
|
||||
options.addStringOption('Xdoclint:none', '-quiet')
|
||||
}
|
||||
|
||||
task javadocJar(type: Jar, dependsOn: javadoc) {
|
||||
archiveClassifier = 'javadoc'
|
||||
classifier = "javadoc"
|
||||
exclude {
|
||||
details -> details.file.getAbsolutePath().contains("/gm/")
|
||||
}
|
||||
from javadoc.destinationDir
|
||||
}
|
||||
publishing {
|
||||
publications {
|
||||
mavenJava(MavenPublication) {
|
||||
groupId project.group
|
||||
artifactId "front-base"
|
||||
version "${version}"
|
||||
from components.java
|
||||
artifact sourceJar
|
||||
artifact javadocJar
|
||||
artifact classJar
|
||||
pom {
|
||||
name = "bdware-front-base"
|
||||
description = "front-base"
|
||||
url = "https://gitee.com/BDWare/front-base"
|
||||
licenses {
|
||||
license {
|
||||
name = "Mulan PSL v2"
|
||||
url = "http://license.coscl.org.cn/MulanPSL2"
|
||||
}
|
||||
}
|
||||
developers {
|
||||
developer {
|
||||
id = "dataware"
|
||||
email = "caihq@pku.edu.cn"
|
||||
}
|
||||
}
|
||||
scm {
|
||||
connection = "scm:git:https://gitee.com/BDWare/front-base.git"
|
||||
developerConnection = "scm:git:https://gitee.com/BDWare/front-base.git"
|
||||
url = "https://gitee.com/BDWare/front-base"
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
repositories {
|
||||
maven {
|
||||
name 'bdwareSnapshot'
|
||||
url 'https://oss.sonatype.org/content/repositories/snapshots'
|
||||
credentials {
|
||||
username = "${NEXUS_USERNAME}"
|
||||
password = "${NEXUS_PASSWORD}"
|
||||
}
|
||||
}
|
||||
maven {
|
||||
name 'bdware'
|
||||
url 'https://oss.sonatype.org/service/local/staging/deploy/maven2'
|
||||
credentials {
|
||||
username = "${NEXUS_USERNAME}"
|
||||
password = "${NEXUS_PASSWORD}"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
signing {
|
||||
sign publishing.publications.mavenJava
|
||||
}
|
@ -45,6 +45,8 @@ public class HttpFileHandleAdapter extends SimpleChannelInboundHandler<FullHttpR
|
||||
headers.set(HttpHeaderNames.CONTENT_TYPE, "image/x-icon;");
|
||||
} else if (path.endsWith(".svg")) {
|
||||
headers.set(HttpHeaderNames.CONTENT_TYPE, "text/xml;charset=utf-8");
|
||||
} else if (path.endsWith(".ypk")) {
|
||||
headers.set(HttpHeaderNames.CONTENT_TYPE, "application/ypk");
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user