X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=build.gradle;h=1f16133781ea77a4959c88cdd8cd07f01831ebb4;hb=f62fb8ea4730ed1d33acbd766543628435a444f3;hp=3aa4c4541258b317225fabeec33ec8c992442330;hpb=7d8ba6c44b69e49f071c082d19470c399ff84255;p=jalview.git diff --git a/build.gradle b/build.gradle index 3aa4c45..1f16133 100644 --- a/build.gradle +++ b/build.gradle @@ -594,10 +594,13 @@ task convertBuildingMD(type: Exec) { pandoc = System.getProperty("user.home")+"/buildtools/pandoc/bin/pandoc" } - if (pandoc != null && file(pandoc).exists()) { - commandLine pandoc, '-s', '-o', buildingHTML, '--metadata', 'pagetitle="Building Jalview from Source"', '--toc', '-H', css, buildingMD - } else { - commandLine "true" + doFirst { + if (pandoc != null && file(pandoc).exists()) { + commandLine pandoc, '-s', '-o', buildingHTML, '--metadata', 'pagetitle="Building Jalview from Source"', '--toc', '-H', css, buildingMD + } else { + println("Cannot find pandoc. Skipping convert building.md to HTML") + throw new StopExecutionException() + } } ignoreExitValue true @@ -721,7 +724,7 @@ task compileLinkCheck(type: JavaCompile) { outputs.file("$jalviewDir/$utilsDir/BufferedLineReader.class") } -def helplinkscheckeroutputfile = file("$jalviewDir/$utilsDir/HelpLinksChecker.out") +def helplinkscheckertouchfile = file("$jalviewDir/$utilsDir/HelpLinksChecker.touch") task linkCheck(type: JavaExec) { dependsOn prepare, compileLinkCheck classpath = files("$jalviewDir/$utilsDir") @@ -730,12 +733,12 @@ task linkCheck(type: JavaExec) { def help = "$classes/$helpDir" args = [ "$classes/$helpDir", "-nointernet" ] - doFirst { - helplinkscheckeroutputfile.createNewFile() - standardOutput new FileOutputStream(helplinkscheckeroutputfile, false) + doLast { + helplinkscheckertouchfile.createNewFile() } - outputs.file(helplinkscheckeroutputfile) + inputs.dir("$classes/$helpDir") + outputs.file(helplinkscheckertouchfile) } task cleanPackageDir(type: Delete) {