diff options
author | Florian Zschocke <f.zschocke+git@gmail.com> | 2020-10-22 20:43:45 +0200 |
---|---|---|
committer | Florian Zschocke <f.zschocke+git@gmail.com> | 2020-10-22 20:43:45 +0200 |
commit | 6d694fd39bc4c794189df2ca773390ed0f5c8ffa (patch) | |
tree | 04cad7518d86ab6a756b6a59a5bd5b04f55496ea /build.xml | |
parent | a5cb3bda71840d0257c21ba56a7d6abf4a3a5938 (diff) | |
download | gitblit-6d694fd39bc4c794189df2ca773390ed0f5c8ffa.tar.gz gitblit-6d694fd39bc4c794189df2ca773390ed0f5c8ffa.zip |
build: Activate JaCoCo explicitly for Ant build
When building with Ant, instead of Moxie, JaCoCo is not included in the
classpath. So explicitly initialise the full `jacocoant.jar` from the
`.moxie` repository.
For this we had to switch the dependency to use the `nodeps` jar which
includes all dependencies.
Diffstat (limited to 'build.xml')
-rw-r--r-- | build.xml | 11 |
1 files changed, 9 insertions, 2 deletions
@@ -12,7 +12,9 @@ <property name="moxie.url" value="http://gitblit.github.io/moxie/maven" />
<property name="moxie.jar" value="moxie-toolkit-${moxie.version}.jar" />
<property name="moxie.dir" value="${user.home}/.moxie" />
-
+
+ <property name="jacoco.version" value="0.8.4" />
+
<!-- Download Moxie from it's Maven repository to user.home -->
<mkdir dir="${moxie.dir}" />
<get src="${moxie.url}/com/gitblit/moxie/moxie-toolkit/${moxie.version}/${moxie.jar}"
@@ -46,7 +48,12 @@ If it exists, build.properties is automatically loaded.
Explicitly set mxroot allowing CI servers to override the default. -->
<mx:init verbose="no" mxroot="${moxie.dir}" />
-
+
+ <!-- Register JaCoCo tasks -->
+ <taskdef uri="antlib:org.jacoco.ant">
+ <classpath location="${moxie.dir}/remote/repo1.maven.org_maven2/org/jacoco/org.jacoco.ant/${jacoco.version}/org.jacoco.ant-${jacoco.version}-nodeps.jar" />
+ </taskdef>
+
<!-- Set Ant project properties -->
<property name="release.tag" value="v${project.version}" />
<property name="currentRelease.tag" value="v${project.releaseVersion}" />
|