From 9f035c21536bc08670d1ee5f8c2f74a7340bfa88 Mon Sep 17 00:00:00 2001 From: Simon Harrer Date: Tue, 27 Oct 2015 09:34:41 +0100 Subject: [PATCH 1/4] Enable coverity --- README.md | 2 ++ build.gradle | 2 ++ circle.yml | 1 + 3 files changed, 5 insertions(+) diff --git a/README.md b/README.md index d548b0f4fb2..1fd895e1a48 100644 --- a/README.md +++ b/README.md @@ -3,6 +3,8 @@ [![CircleCI](https://img.shields.io/circleci/project/JabRef/jabref.svg)](https://circleci.com/gh/JabRef/jabref) [![Dependency Status](https://www.versioneye.com/user/projects/557f2723386664002000009c/badge.svg?style=flat)](https://www.versioneye.com/user/projects/557f2723386664002000009c) [![codecov.io](https://codecov.io/github/JabRef/jabref/coverage.svg?branch=master)](https://codecov.io/github/JabRef/jabref?branch=master) +[![Coverity Status](https://badges.ondemand.coverity.com/streams/unhetcisrp7nna3b5cilqev4bk)](https://ondemand.coverity.com/streams/unhetcisrp7nna3b5cilqev4bk) +[![Coverage Status](https://coveralls.io/repos/JabRef/jabref/badge.svg)](https://coveralls.io/r/JabRef/jabref) [![License](https://img.shields.io/badge/license-GPLv2-blue.svg)](http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt) [![Join the chat at https://gitter.im/JabRef/jabref](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/JabRef/jabref?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![Donation](https://img.shields.io/badge/donate-paypal-orange.svg)](https://www.paypal.com/cgi-bin/webscr?item_name=JabRef+Bibliography+Manager&cmd=_donations&lc=US¤cy_code=EUR&business=jabrefmail%40gmail.com) diff --git a/build.gradle b/build.gradle index 228e00fce8b..b350a144aa4 100644 --- a/build.gradle +++ b/build.gradle @@ -6,6 +6,7 @@ plugins { id "com.github.kt3k.coveralls" version "2.4.0" id "edu.sc.seis.macAppBundle" version "2.1.1" id "com.github.youribonnaffe.gradle.format" version "1.2" + id "com.coverity.ondemand" version "1.3.708" } apply plugin: "java" @@ -27,6 +28,7 @@ task wrapper(type: Wrapper) { gradleVersion = '2.8' } + repositories { jcenter() } diff --git a/circle.yml b/circle.yml index 89d989550c2..3cc5757132a 100644 --- a/circle.yml +++ b/circle.yml @@ -18,6 +18,7 @@ test: override: - TERM=dumb ./gradlew test post: + - TERM=dumb ./gradlew coverityCheck - mkdir -p $CIRCLE_TEST_REPORTS/junit/ - find . -type f -regex ".*/build/test-results/.*xml" -exec cp {} $CIRCLE_TEST_REPORTS/junit/ \; - TERM=dumb ./gradlew jacocoTestReport coveralls From 522e5a6945a003ad5403cbf3253fedb03c1fe8c0 Mon Sep 17 00:00:00 2001 From: Simon Harrer Date: Thu, 29 Oct 2015 17:51:59 +0100 Subject: [PATCH 2/4] Use workaround version of coveralls --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index b350a144aa4..7e68820fed0 100644 --- a/build.gradle +++ b/build.gradle @@ -3,7 +3,7 @@ import org.gradle.internal.os.OperatingSystem plugins { id 'com.github.johnrengelman.shadow' version '1.2.2' id "edu.sc.seis.launch4j" version "1.1.4" - id "com.github.kt3k.coveralls" version "2.4.0" + id "com.github.kt3k.coveralls" version "2.4.0x" id "edu.sc.seis.macAppBundle" version "2.1.1" id "com.github.youribonnaffe.gradle.format" version "1.2" id "com.coverity.ondemand" version "1.3.708" From 31ffd25bf4e379e661bc550141c67f02974abe19 Mon Sep 17 00:00:00 2001 From: Simon Harrer Date: Tue, 10 Nov 2015 09:53:22 +0100 Subject: [PATCH 3/4] Only execute coverity on CI server --- build.gradle | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/build.gradle b/build.gradle index 7e68820fed0..38f79d14d57 100644 --- a/build.gradle +++ b/build.gradle @@ -16,6 +16,17 @@ apply plugin: 'jacoco' apply plugin: 'com.github.kt3k.coveralls' apply from: 'eclipse.gradle' +// HACK to disable coverityCheck task when not on CI server +// necessary as coverity automatically adds check.dependsOn coverityCheck +gradle.taskGraph.whenReady { taskGraph -> + def tasks = taskGraph.getAllTasks() + if (System.env.CI == null) { + tasks.findAll {it.name.startsWith('coverityCheck')}.each { task -> + task.enabled = false + } + } +} + group = "net.sf.jabref" version = "2.80dev" project.ext.threeDotVersion = "2.80.0.0" From 53dc24953d7689f4df37e6f98cbec22371e7bb84 Mon Sep 17 00:00:00 2001 From: Simon Harrer Date: Tue, 10 Nov 2015 09:55:09 +0100 Subject: [PATCH 4/4] coveralls.io does not work anymore with our repo --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index 1fd895e1a48..e4a12a053d2 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,6 @@ [![Dependency Status](https://www.versioneye.com/user/projects/557f2723386664002000009c/badge.svg?style=flat)](https://www.versioneye.com/user/projects/557f2723386664002000009c) [![codecov.io](https://codecov.io/github/JabRef/jabref/coverage.svg?branch=master)](https://codecov.io/github/JabRef/jabref?branch=master) [![Coverity Status](https://badges.ondemand.coverity.com/streams/unhetcisrp7nna3b5cilqev4bk)](https://ondemand.coverity.com/streams/unhetcisrp7nna3b5cilqev4bk) -[![Coverage Status](https://coveralls.io/repos/JabRef/jabref/badge.svg)](https://coveralls.io/r/JabRef/jabref) [![License](https://img.shields.io/badge/license-GPLv2-blue.svg)](http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt) [![Join the chat at https://gitter.im/JabRef/jabref](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/JabRef/jabref?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![Donation](https://img.shields.io/badge/donate-paypal-orange.svg)](https://www.paypal.com/cgi-bin/webscr?item_name=JabRef+Bibliography+Manager&cmd=_donations&lc=US¤cy_code=EUR&business=jabrefmail%40gmail.com)