aboutsummaryrefslogtreecommitdiff
path: root/build.gradle
diff options
context:
space:
mode:
authorAndreas Fitzek <andreas.fitzek@iaik.tugraz.at>2014-09-26 09:28:29 +0200
committerAndreas Fitzek <andreas.fitzek@iaik.tugraz.at>2014-09-26 09:28:29 +0200
commit1ae266dacef1559dc601c9bc5552529ffb04fbaa (patch)
treef518456b5def3d90fc4e059f62ca69f9a5470da6 /build.gradle
parentf758f4a18fa6b720b46f2183251b9ce6f2839a3d (diff)
downloadpdf-as-4-1ae266dacef1559dc601c9bc5552529ffb04fbaa.tar.gz
pdf-as-4-1ae266dacef1559dc601c9bc5552529ffb04fbaa.tar.bz2
pdf-as-4-1ae266dacef1559dc601c9bc5552529ffb04fbaa.zip
Changed Version to 4.0.1, added CVE check
Diffstat (limited to 'build.gradle')
-rw-r--r--build.gradle35
1 files changed, 34 insertions, 1 deletions
diff --git a/build.gradle b/build.gradle
index 6740e3c0..93fe2674 100644
--- a/build.gradle
+++ b/build.gradle
@@ -17,7 +17,7 @@ subprojects {
}
sourceCompatibility = 1.6
- version = '4.0.0-RC11'
+ version = '4.0.1'
project.ext{
releaseRepoUrl = "file://${project(':').projectDir}/../mvn-repo/releases"
snapshotRepoUrl = "file://${project(':').projectDir}/../mvn-repo/snapshots"
@@ -30,6 +30,13 @@ subprojects {
jar { manifest.attributes provider: 'EGIZ', 'Specification-Version': getCheckedOutGitCommitHash(), 'Implementation-Version': project.version }
+ task copyDeps(type: Copy) {
+ from configurations.runtime
+ into (new File(rootDir, 'build/alldependencies')).toString()
+ }
+
+ checkCVE.dependsOn copyDeps
+
uploadArchives {
repositories.mavenDeployer {
repository(url: project.releaseRepoUrl)
@@ -38,6 +45,32 @@ subprojects {
}
}
+configurations {
+ cveCheck
+}
+
+// Assign dependencies to the sshAntTask configuration.
+dependencies {
+ cveCheck 'org.owasp:dependency-check-ant:1.2.5'
+}
+
+task checkCVE << {
+ // Redefine checkCVEAnt Ant task, with the classpath property set to our newly defined
+ // cveCheck configuration classpath.
+ ant.taskdef(name: 'checkCVEAnt', classname: 'org.owasp.dependencycheck.taskdefs.DependencyCheckTask',
+ classpath: configurations.cveCheck.asPath)
+
+ // executing checkCVEAnt Task
+ ant.checkCVEAnt(
+ applicationname: "PDF-AS",
+ reportoutputdirectory: (new File(rootDir, 'releases/cvecheck/' + project.name)).toString(),
+ reportformat: "ALL") {
+ fileset(dir: (new File(rootDir, 'build/alldependencies')).toString()) {
+ include(name: '**/**')
+ }
+ }
+}
+
def getCheckedOutGitCommitHash() {
def gitFolder = "$projectDir/.git/"
def takeFromHash = 40