mirror of
https://github.com/spring-projects/spring-security.git
synced 2025-06-28 23:02:15 +00:00
Added generatePom task
This can be used to generate the pom.xml for adding the Spring Security snapshot jars as a Maven Dependency to another project. For example, if mywebapp requires the Spring Security 3.1.4.CI-SNAPSHOT jars one could generate the pom.xml files and then use that to convert the project into a valid Maven project within the IDE. Then the SNAPSHOT dependendies could be added to mywebapp. This prevents the need to install the SNAPSHOT dependencies in the local Maven repository.
This commit is contained in:
parent
39918b4a01
commit
cf9a392b0a
@ -48,4 +48,21 @@ def customizePom(pom, gradleProject) {
|
||||
builder.length = 0 // delete existing content
|
||||
builder.append(file("build/pom.xml").text)
|
||||
}
|
||||
}
|
||||
|
||||
task generatePom {
|
||||
group = 'Build'
|
||||
description = 'Generates the Maven pom.xml'
|
||||
|
||||
ext.generatedPomFileName = 'pom.xml'
|
||||
|
||||
inputs.files('**/*.gradle')
|
||||
outputs.files(generatedPomFileName)
|
||||
|
||||
doLast() {
|
||||
def p = pom {}
|
||||
customizePom(p, project)
|
||||
p.writeTo(generatedPomFileName)
|
||||
}
|
||||
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user