fix(gradlebuildconfig): add pom.xml & change swaggerV2 from runtime to compile for maven project (#438)
add new pom.xml generate task in jar task && change swaggerV2 from implementation to api
This commit is contained in:
2
.gitignore
vendored
2
.gitignore
vendored
@@ -6,3 +6,5 @@ build
|
||||
/.classpath
|
||||
/.project
|
||||
/.settings/
|
||||
*.ipr
|
||||
*.iws
|
||||
@@ -35,6 +35,7 @@ ext {
|
||||
|
||||
configure(project.coreProjects) {
|
||||
apply plugin: 'java'
|
||||
apply plugin: 'java-library'
|
||||
apply plugin: 'maven'
|
||||
apply plugin: 'maven-publish'
|
||||
apply from: "${rootDir}/publishing.gradle"
|
||||
@@ -100,6 +101,10 @@ subprojects {
|
||||
// exclude subprojects that don't produce a jar file or by design.
|
||||
if (!project.name.equals('swagger2markup-bom') && !project.name.equals('swagger2markup-documentation')) {
|
||||
jar {
|
||||
into("META-INF/maven/$project.group/$project.name") {
|
||||
from {generatePomFileForMavenJavaPublication}
|
||||
rename ".*", "pom.xml"
|
||||
}
|
||||
inputs.property('moduleName', moduleName)
|
||||
manifest.attributes(
|
||||
'Automatic-Module-Name': moduleName
|
||||
|
||||
@@ -28,7 +28,7 @@ dependencies {
|
||||
implementation implLibraries.guava
|
||||
implementation implLibraries.paleo
|
||||
implementation implLibraries.slf4j
|
||||
implementation implLibraries.swaggerV2
|
||||
api implLibraries.swaggerV2
|
||||
implementation implLibraries.vavr
|
||||
testImplementation testLibraries.assertj
|
||||
testImplementation testLibraries.assertjDiff
|
||||
|
||||
Reference in New Issue
Block a user