diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 73230f52..509ab872 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,4 +1,4 @@ -name: Build +name: CI on: push: @@ -14,57 +14,36 @@ jobs: os: - ubuntu-latest - macos-latest - java-version: + java_version: - 8 - 11 - - 13 + - 17 exclude: - os: macos-latest java_version: 8 - os: macos-latest - java_version: 13 + java_version: 17 + fail-fast: false runs-on: ${{ matrix.os }} steps: - # https://github.com/actions/checkout - - uses: actions/checkout@v2 + - uses: actions/checkout@v4.1.1 - # https://github.com/gradle/wrapper-validation-action - - uses: gradle/wrapper-validation-action@v1 - - # https://github.com/actions/setup-java - - uses: actions/setup-java@v2 - with: - distribution: adopt - java-version: ${{ matrix.java-version }} - - # https://github.com/actions/cache - - name: Cache Gradle packages - uses: actions/cache@v2 + - uses: actions/setup-java@v4.0.0 with: - path: | - ~/.gradle/caches - ~/.gradle/wrapper - key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} - restore-keys: | - ${{ runner.os }}-gradle- - - - name: Install Linux prerequisites - if: ${{ runner.os == 'Linux' }} - run: | - sudo apt update - sudo apt -y install sox speech-tools + distribution: zulu + java-version: ${{ matrix.java_version }} - - name: Install macOS prerequisites - if: ${{ runner.os == 'macOS' }} - run: brew install speech-tools - - - name: Build with Gradle + - if: runner.os == 'Linux' env: - GRADLE_OPTS: -Dorg.gradle.daemon=false - run: ./gradlew build + DEBIAN_FRONTEND: noninteractive + run: > + sudo apt-get -qq update && + sudo apt-get -qq install sox speech-tools + + - if: runner.os == 'macOS' + run: brew install sox speech-tools - - name: Cleanup Gradle Cache - run: | - rm -f ~/.gradle/caches/modules-2/modules-2.lock - rm -f ~/.gradle/caches/modules-2/gc.properties + - uses: gradle/gradle-build-action@v2.12.0 + with: + arguments: build --warning-mode all diff --git a/CHANGELOG.md b/CHANGELOG.md index fd8cbb97..d9f99da8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,10 @@ Gradle MaryTTS voicebuilding plugin - Plugin usage documented in readme - Testing on OpenJDK 11 and 13 +### Removed + +- Support for Gradle versions older than v7.0 + ### Changed - Migrate testing from Travis CI to GitHub Actions diff --git a/README.md b/README.md index c15829da..791c90c5 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ plugins { ``` For details, see https://plugins.gradle.org/plugin/de.dfki.mary.voicebuilding-legacy. -Note that Gradle v6.2 or higher is required. +Note that Gradle v7.0 or higher is required. Prerequisites ------------- diff --git a/build.gradle b/build.gradle index 5d84f4b6..5a0ed38a 100644 --- a/build.gradle +++ b/build.gradle @@ -58,27 +58,49 @@ pluginBundle { } repositories { - jcenter() - gradlePluginPortal() + mavenCentral() + exclusiveContent { + forRepository { + maven { + name 'DFKI-MLT' + url 'https://raw.githubusercontent.com/DFKI-MLT/Maven-Repository/main' + } + } + filter { + includeGroup 'de.dfki.lt.jtok' + } + } + exclusiveContent { + forRepository { + gradlePluginPortal() + } + filter { + includeModule 'de.dfki.mary', 'gradle-marytts-component-plugin' + } + } } dependencies { implementation localGroovy() - implementation group: 'de.dfki.mary', name: 'marytts-runtime', version: maryttsVersion, { + implementation group: 'de.dfki.mary', name: 'marytts-runtime', version: libs.versions.marytts.get(), { exclude group: '*', module: 'groovy-all' - exclude group: '*', module: 'mwdumper' - exclude group: '*', module: 'sgt' + exclude group: 'com.twmacinta', module: 'fast-md5' + exclude group: 'gov.nist.math', module: 'Jampack' } - implementation group: 'de.dfki.mary', name: 'gradle-marytts-component-plugin', version: '0.2.2' - implementation group: 'org.m2ci.msp', name: 'gradle-praat-wrapper-plugin', version: '0.6' - implementation group: 'org.m2ci.msp', name: 'jtgt', version: '0.6.1' - testImplementation group: 'org.testng', name: 'testng', version: '7.0.0' + implementation group: 'de.dfki.mary', name: 'gradle-marytts-component-plugin', version: '0.3.2' + implementation group: 'io.github.m2ci-msp', name: 'gradle-praat-wrapper-plugin', version: '0.7.0' + implementation group: 'io.github.m2ci-msp', name: 'jtgt', version: '0.7.0' + testImplementation group: 'org.testng', name: 'testng', version: '7.5.1' testImplementation group: 'xmlunit', name: 'xmlunit', version: '1.6' } +java { + withSourcesJar() +} + processResources { doLast { - file("$destinationDir/maryttsVersion.txt").text = maryttsVersion + file("$destinationDir/maryttsVersion.txt").text = libs.versions.marytts.get() } } @@ -94,25 +116,14 @@ test { } } failFast = true - doFirst { - // path to shared testkit gradle home - systemProperty 'testProjectDir', temporaryDir - // dynamic marytts version - systemProperty 'maryVersion', maryttsVersion - } -} - -task sourceJar(type: Jar) { - from sourceSets.main.allJava + systemProperty 'java.io.tmpdir', temporaryDir + systemProperty 'maryVersion', libs.versions.marytts.get() } publishing { publications { mavenJava(MavenPublication) { from components.java - artifact sourceJar { - classifier 'sources' - } } } repositories { diff --git a/gradle.properties b/gradle.properties deleted file mode 100644 index 712b52dd..00000000 --- a/gradle.properties +++ /dev/null @@ -1 +0,0 @@ -maryttsVersion = 5.2 diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar index 490fda85..afba1092 100644 Binary files a/gradle/wrapper/gradle-wrapper.jar and b/gradle/wrapper/gradle-wrapper.jar differ diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index a4b44297..c7d437bb 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-6.3-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.4-bin.zip +networkTimeout=10000 zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/gradlew b/gradlew index 2fe81a7d..65dcd68d 100755 --- a/gradlew +++ b/gradlew @@ -1,7 +1,7 @@ -#!/usr/bin/env sh +#!/bin/sh # -# Copyright 2015 the original author or authors. +# Copyright © 2015-2021 the original authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -17,78 +17,113 @@ # ############################################################################## -## -## Gradle start up script for UN*X -## +# +# Gradle start up script for POSIX generated by Gradle. +# +# Important for running: +# +# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is +# noncompliant, but you have some other compliant shell such as ksh or +# bash, then to run this script, type that shell name before the whole +# command line, like: +# +# ksh Gradle +# +# Busybox and similar reduced shells will NOT work, because this script +# requires all of these POSIX shell features: +# * functions; +# * expansions «$var», «${var}», «${var:-default}», «${var+SET}», +# «${var#prefix}», «${var%suffix}», and «$( cmd )»; +# * compound commands having a testable exit status, especially «case»; +# * various built-in commands including «command», «set», and «ulimit». +# +# Important for patching: +# +# (2) This script targets any POSIX shell, so it avoids extensions provided +# by Bash, Ksh, etc; in particular arrays are avoided. +# +# The "traditional" practice of packing multiple parameters into a +# space-separated string is a well documented source of bugs and security +# problems, so this is (mostly) avoided, by progressively accumulating +# options in "$@", and eventually passing that to Java. +# +# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS, +# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly; +# see the in-line comments for details. +# +# There are tweaks for specific operating systems such as AIX, CygWin, +# Darwin, MinGW, and NonStop. +# +# (3) This script is generated from the Groovy template +# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt +# within the Gradle project. +# +# You can find Gradle at https://github.com/gradle/gradle/. +# ############################################################################## # Attempt to set APP_HOME + # Resolve links: $0 may be a link -PRG="$0" -# Need this for relative symlinks. -while [ -h "$PRG" ] ; do - ls=`ls -ld "$PRG"` - link=`expr "$ls" : '.*-> \(.*\)$'` - if expr "$link" : '/.*' > /dev/null; then - PRG="$link" - else - PRG=`dirname "$PRG"`"/$link" - fi +app_path=$0 + +# Need this for daisy-chained symlinks. +while + APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path + [ -h "$app_path" ] +do + ls=$( ls -ld "$app_path" ) + link=${ls#*' -> '} + case $link in #( + /*) app_path=$link ;; #( + *) app_path=$APP_HOME$link ;; + esac done -SAVED="`pwd`" -cd "`dirname \"$PRG\"`/" >/dev/null -APP_HOME="`pwd -P`" -cd "$SAVED" >/dev/null -APP_NAME="Gradle" -APP_BASE_NAME=`basename "$0"` +# This is normally unused +# shellcheck disable=SC2034 +APP_BASE_NAME=${0##*/} +APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' # Use the maximum available, or set MAX_FD != -1 to use that value. -MAX_FD="maximum" +MAX_FD=maximum warn () { echo "$*" -} +} >&2 die () { echo echo "$*" echo exit 1 -} +} >&2 # OS specific support (must be 'true' or 'false'). cygwin=false msys=false darwin=false nonstop=false -case "`uname`" in - CYGWIN* ) - cygwin=true - ;; - Darwin* ) - darwin=true - ;; - MINGW* ) - msys=true - ;; - NONSTOP* ) - nonstop=true - ;; +case "$( uname )" in #( + CYGWIN* ) cygwin=true ;; #( + Darwin* ) darwin=true ;; #( + MSYS* | MINGW* ) msys=true ;; #( + NONSTOP* ) nonstop=true ;; esac CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar + # Determine the Java command to use to start the JVM. if [ -n "$JAVA_HOME" ] ; then if [ -x "$JAVA_HOME/jre/sh/java" ] ; then # IBM's JDK on AIX uses strange locations for the executables - JAVACMD="$JAVA_HOME/jre/sh/java" + JAVACMD=$JAVA_HOME/jre/sh/java else - JAVACMD="$JAVA_HOME/bin/java" + JAVACMD=$JAVA_HOME/bin/java fi if [ ! -x "$JAVACMD" ] ; then die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME @@ -97,7 +132,7 @@ Please set the JAVA_HOME variable in your environment to match the location of your Java installation." fi else - JAVACMD="java" + JAVACMD=java which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. Please set the JAVA_HOME variable in your environment to match the @@ -105,79 +140,105 @@ location of your Java installation." fi # Increase the maximum file descriptors if we can. -if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then - MAX_FD_LIMIT=`ulimit -H -n` - if [ $? -eq 0 ] ; then - if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then - MAX_FD="$MAX_FD_LIMIT" - fi - ulimit -n $MAX_FD - if [ $? -ne 0 ] ; then - warn "Could not set maximum file descriptor limit: $MAX_FD" - fi - else - warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" - fi +if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then + case $MAX_FD in #( + max*) + # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC3045 + MAX_FD=$( ulimit -H -n ) || + warn "Could not query maximum file descriptor limit" + esac + case $MAX_FD in #( + '' | soft) :;; #( + *) + # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC3045 + ulimit -n "$MAX_FD" || + warn "Could not set maximum file descriptor limit to $MAX_FD" + esac fi -# For Darwin, add options to specify how the application appears in the dock -if $darwin; then - GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" -fi +# Collect all arguments for the java command, stacking in reverse order: +# * args from the command line +# * the main class name +# * -classpath +# * -D...appname settings +# * --module-path (only if needed) +# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables. # For Cygwin or MSYS, switch paths to Windows format before running java -if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then - APP_HOME=`cygpath --path --mixed "$APP_HOME"` - CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` - JAVACMD=`cygpath --unix "$JAVACMD"` - - # We build the pattern for arguments to be converted via cygpath - ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` - SEP="" - for dir in $ROOTDIRSRAW ; do - ROOTDIRS="$ROOTDIRS$SEP$dir" - SEP="|" - done - OURCYGPATTERN="(^($ROOTDIRS))" - # Add a user-defined pattern to the cygpath arguments - if [ "$GRADLE_CYGPATTERN" != "" ] ; then - OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" - fi +if "$cygwin" || "$msys" ; then + APP_HOME=$( cygpath --path --mixed "$APP_HOME" ) + CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" ) + + JAVACMD=$( cygpath --unix "$JAVACMD" ) + # Now convert the arguments - kludge to limit ourselves to /bin/sh - i=0 - for arg in "$@" ; do - CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` - CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option - - if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition - eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` - else - eval `echo args$i`="\"$arg\"" + for arg do + if + case $arg in #( + -*) false ;; # don't mess with options #( + /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath + [ -e "$t" ] ;; #( + *) false ;; + esac + then + arg=$( cygpath --path --ignore --mixed "$arg" ) fi - i=`expr $i + 1` + # Roll the args list around exactly as many times as the number of + # args, so each arg winds up back in the position where it started, but + # possibly modified. + # + # NB: a `for` loop captures its iteration list before it begins, so + # changing the positional parameters here affects neither the number of + # iterations, nor the values presented in `arg`. + shift # remove old arg + set -- "$@" "$arg" # push replacement arg done - case $i in - 0) set -- ;; - 1) set -- "$args0" ;; - 2) set -- "$args0" "$args1" ;; - 3) set -- "$args0" "$args1" "$args2" ;; - 4) set -- "$args0" "$args1" "$args2" "$args3" ;; - 5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; - 6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; - 7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; - 8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; - 9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; - esac fi -# Escape application args -save () { - for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done - echo " " -} -APP_ARGS=`save "$@"` +# Collect all arguments for the java command; +# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of +# shell script including quotes and variable substitutions, so put them in +# double quotes to make sure that they get re-expanded; and +# * put everything else in single quotes, so that it's not re-expanded. + +set -- \ + "-Dorg.gradle.appname=$APP_BASE_NAME" \ + -classpath "$CLASSPATH" \ + org.gradle.wrapper.GradleWrapperMain \ + "$@" + +# Stop when "xargs" is not available. +if ! command -v xargs >/dev/null 2>&1 +then + die "xargs is not available" +fi + +# Use "xargs" to parse quoted args. +# +# With -n1 it outputs one arg per line, with the quotes and backslashes removed. +# +# In Bash we could simply go: +# +# readarray ARGS < <( xargs -n1 <<<"$var" ) && +# set -- "${ARGS[@]}" "$@" +# +# but POSIX shell has neither arrays nor command substitution, so instead we +# post-process each arg (as a line of input to sed) to backslash-escape any +# character that might be a shell metacharacter, then use eval to reverse +# that process (while maintaining the separation between arguments), and wrap +# the whole thing up as a single "set" statement. +# +# This will of course break if any of these variables contains a newline or +# an unmatched quote. +# -# Collect all arguments for the java command, following the shell quoting and substitution rules -eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS" +eval "set -- $( + printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" | + xargs -n1 | + sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' | + tr '\n' ' ' + )" '"$@"' exec "$JAVACMD" "$@" diff --git a/gradlew.bat b/gradlew.bat index 62bd9b9c..93e3f59f 100644 --- a/gradlew.bat +++ b/gradlew.bat @@ -14,7 +14,7 @@ @rem limitations under the License. @rem -@if "%DEBUG%" == "" @echo off +@if "%DEBUG%"=="" @echo off @rem ########################################################################## @rem @rem Gradle startup script for Windows @@ -25,7 +25,8 @@ if "%OS%"=="Windows_NT" setlocal set DIRNAME=%~dp0 -if "%DIRNAME%" == "" set DIRNAME=. +if "%DIRNAME%"=="" set DIRNAME=. +@rem This is normally unused set APP_BASE_NAME=%~n0 set APP_HOME=%DIRNAME% @@ -40,7 +41,7 @@ if defined JAVA_HOME goto findJavaFromJavaHome set JAVA_EXE=java.exe %JAVA_EXE% -version >NUL 2>&1 -if "%ERRORLEVEL%" == "0" goto init +if %ERRORLEVEL% equ 0 goto execute echo. echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. @@ -54,7 +55,7 @@ goto fail set JAVA_HOME=%JAVA_HOME:"=% set JAVA_EXE=%JAVA_HOME%/bin/java.exe -if exist "%JAVA_EXE%" goto init +if exist "%JAVA_EXE%" goto execute echo. echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% @@ -64,38 +65,26 @@ echo location of your Java installation. goto fail -:init -@rem Get command-line arguments, handling Windows variants - -if not "%OS%" == "Windows_NT" goto win9xME_args - -:win9xME_args -@rem Slurp the command line arguments. -set CMD_LINE_ARGS= -set _SKIP=2 - -:win9xME_args_slurp -if "x%~1" == "x" goto execute - -set CMD_LINE_ARGS=%* - :execute @rem Setup the command line set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar + @rem Execute Gradle -"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% +"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* :end @rem End local scope for the variables with windows NT shell -if "%ERRORLEVEL%"=="0" goto mainEnd +if %ERRORLEVEL% equ 0 goto mainEnd :fail rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of rem the _cmd.exe /c_ return code! -if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 -exit /b 1 +set EXIT_CODE=%ERRORLEVEL% +if %EXIT_CODE% equ 0 set EXIT_CODE=1 +if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE% +exit /b %EXIT_CODE% :mainEnd if "%OS%"=="Windows_NT" endlocal diff --git a/settings.gradle b/settings.gradle index dbacb32d..132aa25c 100644 --- a/settings.gradle +++ b/settings.gradle @@ -1 +1,8 @@ rootProject.name = 'gradle-marytts-voicebuilding-plugin' +dependencyResolutionManagement { + versionCatalogs { + libs { + version('marytts', '5.2.1') + } + } +} diff --git a/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingBasePlugin.groovy b/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingBasePlugin.groovy index 739d5995..17376bf3 100644 --- a/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingBasePlugin.groovy +++ b/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingBasePlugin.groovy @@ -2,31 +2,26 @@ package de.dfki.mary.voicebuilding import de.dfki.mary.ComponentPlugin -import de.dfki.mary.voicebuilding.tasks.GenerateVoiceSource import de.dfki.mary.voicebuilding.tasks.GenerateVoiceConfig import org.gradle.api.Plugin import org.gradle.api.Project -import org.gradle.api.plugins.GroovyPlugin -import org.gradle.api.plugins.JavaLibraryPlugin import org.gradle.api.publish.maven.MavenPublication import org.gradle.api.publish.maven.plugins.MavenPublishPlugin +import org.gradle.api.publish.maven.tasks.GenerateMavenPom import org.gradle.api.tasks.JavaExec import org.gradle.api.tasks.WriteProperties -import org.gradle.api.tasks.testing.Test class VoicebuildingBasePlugin implements Plugin { @Override void apply(Project project) { - project.plugins.apply JavaLibraryPlugin - project.plugins.apply GroovyPlugin - project.plugins.apply MavenPublishPlugin - project.plugins.apply ComponentPlugin + project.plugins.apply(ComponentPlugin) + project.plugins.apply(MavenPublishPlugin) project.sourceCompatibility = '1.8' - project.marytts.extensions.create 'voice', VoiceExtension, project - project.marytts.voice.extensions.create 'license', VoiceLicenseExtension, project + project.marytts.extensions.create('voice', VoiceExtension, project) + project.marytts.voice.extensions.create('license', VoiceLicenseExtension, project) project.marytts { component { @@ -37,73 +32,37 @@ class VoicebuildingBasePlugin implements Plugin { } project.dependencies { - api group: 'de.dfki.mary', name: 'marytts-runtime', version: project.marytts.version, { - exclude group: '*', module: 'groovy-all' - } - testImplementation group: 'junit', name: 'junit', version: '4.13' + testImplementation group: 'junit', name: 'junit', version: '4.13.2' integrationTestImplementation localGroovy() - integrationTestImplementation group: 'org.testng', name: 'testng', version: '7.0.0' + integrationTestImplementation group: 'org.testng', name: 'testng', version: '7.5' } - project.afterEvaluate { - project.dependencies { - runtimeOnly "de.dfki.mary:marytts-lang-$project.marytts.voice.language:$project.marytts.version", { - exclude group: '*', module: 'groovy-all' - } - } + project.tasks.register('generateVoiceConfig', GenerateVoiceConfig) { + group = 'MaryTTS Voicebuilding Base' } - - project.tasks.register 'generateVoiceConfig', GenerateVoiceConfig, { - + project.tasks.named('unpackTestSourceTemplates').configure { + resourceNames.add 'VoiceConfigTest.java' } - project.tasks.register 'generateVoiceSource', GenerateVoiceSource, { - dependsOn "generateSource", "generateConfig" - testDirectory = project.file("$project.buildDir/generatedSrc/test/groovy/voice") - integrationTestDirectory = project.file("$project.buildDir/generatedSrc/integrationTest/groovy/voice") - + project.tasks.named('unpackIntegrationTestSourceTemplates').configure { + resourceNames.add 'LoadVoiceIT.groovy' } - project.generateConfig { + project.tasks.named('generateConfig').configure { dependsOn project.tasks.named("generateVoiceConfig") } - project.sourceSets { - test { - groovy { - srcDirs += project.generateVoiceSource.testDirectory.get() - } - } - integrationTest { - groovy { - srcDirs += project.generateVoiceSource.integrationTestDirectory.get() - } - } - } - - project.publishing { publications { mavenJava(MavenPublication) { from project.components.java - pom { - description = project.marytts.voice.description - // TODO: Properties not being resolved lazily in nested license extension, so... - project.afterEvaluate { - licenses { - license { - name = project.marytts.voice.license.name - url = project.marytts.voice.license.url - } - } - } - } } } } - project.task('generatePomProperties', type: WriteProperties) { + project.tasks.register('generatePomProperties', WriteProperties) { + group = 'MaryTTS Voicebuilding Base' outputFile = project.layout.buildDirectory.file('pom.properties') properties = [ groupId : project.group, @@ -112,7 +71,7 @@ class VoicebuildingBasePlugin implements Plugin { ] } - project.processResources { + project.tasks.named('processResources').configure { from project.generatePomProperties, { rename { "META-INF/maven/$project.group/voice-$project.marytts.voice.name/pom.xml" } } @@ -121,10 +80,31 @@ class VoicebuildingBasePlugin implements Plugin { } } - project.task('run', type: JavaExec) { + project.tasks.register('run', JavaExec) { + group = 'MaryTTS Voicebuilding Base' classpath = project.configurations.runtimeClasspath + project.sourceSets.main.output - main = 'marytts.server.Mary' + mainClass.set 'marytts.server.Mary' systemProperty 'log4j.logger.marytts', 'INFO,stderr' } + + project.afterEvaluate { + project.dependencies { + runtimeOnly group: 'de.dfki.mary', name: "marytts-lang-$project.marytts.voice.language", version: project.marytts.version, { + exclude group: '*', module: 'groovy-all' + exclude group: 'com.twmacinta', module: 'fast-md5' + exclude group: 'gov.nist.math', module: 'Jampack' + } + } + + project.tasks.withType(GenerateMavenPom).configureEach { + pom.description = project.marytts.voice.description + pom.licenses { + license { + name = project.marytts.voice.license.name + url = project.marytts.voice.license.url + } + } + } + } } } diff --git a/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingDataPlugin.groovy b/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingDataPlugin.groovy index 148efe1d..dcfcab7d 100644 --- a/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingDataPlugin.groovy +++ b/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingDataPlugin.groovy @@ -26,24 +26,29 @@ class VoicebuildingDataPlugin implements Plugin { project.afterEvaluate { marytts group: 'de.dfki.mary', name: "marytts-lang-$project.marytts.voice.locale.language", version: project.marytts.version, { exclude group: '*', module: 'groovy-all' + exclude group: 'com.twmacinta', module: 'fast-md5' + exclude group: 'gov.nist.math', module: 'Jampack' } } - marytts group: 'de.dfki.mary', name: "marytts-voicebuilding", version: '0.1' + marytts group: 'de.dfki.mary', name: 'marytts-voicebuilding', version: '0.2.1' } def templateTask = project.task('templates', type: CopyClasspathResources) { + group = 'MaryTTS Voicebuilding Data' destDir = project.layout.buildDirectory.dir('templates') resources.add '/de/dfki/mary/voicebuilding/templates/extractPitch.praat' resources.add '/de/dfki/mary/voicebuilding/templates/pitchmarks.praat' } def wavTask = project.task('wav', type: ProcessWav) { + group = 'MaryTTS Voicebuilding Data' dependsOn project.processDataResources srcDir = project.processDataResources.destinationDir destDir = project.layout.buildDirectory.dir('wav') } def basenamesTask = project.task('basenames', type: GenerateBasenamesList) { + group = 'MaryTTS Voicebuilding Data' wavDir = wavTask.destDir textDir = project.layout.buildDirectory.dir('text') labDir = project.layout.buildDirectory.dir('lab') @@ -51,6 +56,7 @@ class VoicebuildingDataPlugin implements Plugin { } def praatPitchExtractorTask = project.task('praatPitchExtractor', type: PraatExtractPitch) { + group = 'MaryTTS Voicebuilding Data' dependsOn project.praat, templateTask basenamesFile = basenamesTask.destFile scriptFile = templateTask.destDir.file('extractPitch.praat') @@ -59,6 +65,7 @@ class VoicebuildingDataPlugin implements Plugin { } def praatPitchmarkerTask = project.task('praatPitchmarker', type: PraatExtractPitchmarks) { + group = 'MaryTTS Voicebuilding Data' dependsOn project.praat, templateTask basenamesFile = basenamesTask.destFile scriptFile = templateTask.destDir.file('pitchmarks.praat') @@ -68,12 +75,14 @@ class VoicebuildingDataPlugin implements Plugin { } def pitchmarkConverterTask = project.task('pitchmarkConverter', type: PitchmarkConverter) { + group = 'MaryTTS Voicebuilding Data' basenamesFile = basenamesTask.destFile srcDir = praatPitchmarkerTask.destDir destDir = project.layout.buildDirectory.dir('pm') } project.task('mcepExtractor', type: ExtractMcep) { + group = 'MaryTTS Voicebuilding Data' basenamesFile = basenamesTask.destFile wavDir = wavTask.destDir pmDir = pitchmarkConverterTask.destDir @@ -81,6 +90,7 @@ class VoicebuildingDataPlugin implements Plugin { } def generateAllophonesTask = project.task('generateAllophones', type: MaryInterfaceBatchTask) { + group = 'MaryTTS Voicebuilding Data' srcDir = project.layout.buildDirectory.dir('text') destDir = project.layout.buildDirectory.dir('prompt_allophones') inputType = 'TEXT' @@ -91,6 +101,7 @@ class VoicebuildingDataPlugin implements Plugin { } project.task('generatePhoneFeatures', type: MaryInterfaceBatchTask) { + group = 'MaryTTS Voicebuilding Data' srcDir = generateAllophonesTask.destDir destDir = project.layout.buildDirectory.dir('phonefeatures') inputType = 'ALLOPHONES' @@ -101,6 +112,7 @@ class VoicebuildingDataPlugin implements Plugin { } project.task('generateHalfPhoneFeatures', type: MaryInterfaceBatchTask) { + group = 'MaryTTS Voicebuilding Data' srcDir = generateAllophonesTask.destDir destDir = project.layout.buildDirectory.dir('halfphonefeatures') inputType = 'ALLOPHONES' diff --git a/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingFestvoxPlugin.groovy b/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingFestvoxPlugin.groovy index 5656367e..1ca50e12 100644 --- a/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingFestvoxPlugin.groovy +++ b/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingFestvoxPlugin.groovy @@ -28,12 +28,14 @@ class VoicebuildingFestvoxPlugin implements Plugin { } project.task('text', type: FestvoxExtractText) { + group = 'MaryTTS Voicebuilding FestVox' dependsOn project.tasks.findByName('processDataResources') srcFile = project.file("$project.sourceSets.data.output.resourcesDir/txt.done.data") destDir = project.layout.buildDirectory.dir('text') } project.task('lab', type: FestvoxExtractLab) { + group = 'MaryTTS Voicebuilding FestVox' srcFiles = project.files(project.tasks.getByName('processDataResources')) destDir = project.layout.buildDirectory.dir('lab') mapping = [ diff --git a/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingLegacyPlugin.groovy b/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingLegacyPlugin.groovy index 68b8603e..aa7b71ff 100644 --- a/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingLegacyPlugin.groovy +++ b/src/main/groovy/de/dfki/mary/voicebuilding/VoicebuildingLegacyPlugin.groovy @@ -18,25 +18,29 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('processPhoneLabels', type: ProcessPhoneLabels) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile srcDir = project.layout.buildDirectory.dir('lab') destDir = project.layout.buildDirectory.dir('lab_processed') } project.task('alignLabelsWithPrompts', type: AlignLabelsWithPrompts) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile - labDir = project.layout.buildDirectory.dir('lab') + labDir = project.tasks.getByName("processPhoneLabels").destDir maryXmlDir = project.tasks.getByName('generateAllophones').destDir destDir = project.layout.buildDirectory.dir('allophones') } project.task('splitPhoneLabelsIntoHalfPhones', type: SplitPhoneLabelsIntoHalfPhones) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile srcDir = project.processPhoneLabels.destDir destDir = project.layout.buildDirectory.dir('halfphonelab_aligned') } project.task('phoneUnitFileMaker', type: PhoneUnitFileMaker) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile srcDir = project.processPhoneLabels.destDir srcExt = 'lab' @@ -46,6 +50,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('halfPhoneUnitFileMaker', type: PhoneUnitFileMaker) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile srcDir = project.splitPhoneLabelsIntoHalfPhones.destDir srcExt = 'hplab' @@ -55,10 +60,12 @@ class VoicebuildingLegacyPlugin implements Plugin { } def featureListerTask = project.task('featureLister', type: FeatureListerTask) { + group = 'MaryTTS Voicebuilding Legacy' destFile = project.legacyBuildDir.get().file('features.txt') } def phoneUnitFeatureListerTask = project.task('phoneUnitFeatureLister', type: PhoneUnitFeatureLister) { + group = 'MaryTTS Voicebuilding Legacy' srcFile = featureListerTask.destFile destFile = project.layout.buildDirectory.file('phoneUnitFeatures.txt') featureToListFirst = 'phone' @@ -66,6 +73,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('phoneUnitFeatureComputer', type: MaryInterfaceBatchTask) { + group = 'MaryTTS Voicebuilding Legacy' srcDir = project.alignLabelsWithPrompts.destDir destDir = project.layout.buildDirectory.dir('phonefeatures') inputType = 'ALLOPHONES' @@ -76,18 +84,21 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('generatePhoneFeatureDefinitionFile', type: GeneratePhoneFeatureDefinitionFile) { + group = 'MaryTTS Voicebuilding Legacy' srcDir = project.phoneUnitFeatureComputer.destDir srcExt = project.phoneUnitFeatureComputer.outputExt destFile = project.legacyBuildDir.get().file('phoneUnitFeatureDefinition.txt') } def halfPhoneUnitFeatureListerTask = project.task('halfPhoneUnitFeatureLister', type: PhoneUnitFeatureLister) { + group = 'MaryTTS Voicebuilding Legacy' srcFile = featureListerTask.destFile destFile = project.layout.buildDirectory.file('halfPhoneUnitFeatures.txt') featureToListFirst = 'halfphone_unitname' } project.task('halfPhoneUnitFeatureComputer', type: MaryInterfaceBatchTask) { + group = 'MaryTTS Voicebuilding Legacy' dependsOn featureListerTask srcDir = project.alignLabelsWithPrompts.destDir destDir = project.layout.buildDirectory.dir('halfphonefeatures') @@ -99,12 +110,14 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('generateHalfPhoneFeatureDefinitionFile', type: GeneratePhoneFeatureDefinitionFile) { + group = 'MaryTTS Voicebuilding Legacy' srcDir = project.halfPhoneUnitFeatureComputer.destDir srcExt = project.halfPhoneUnitFeatureComputer.outputExt destFile = project.legacyBuildDir.get().file('halfphoneUnitFeatureDefinition.txt') } project.task('makeBasenameDatagrams', type: MakeBasenameDatagrams) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile sampleRate = project.marytts.voice.samplingRate pmDir = project.tasks.getByName('pitchmarkConverter').destDir @@ -112,6 +125,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('basenameTimelineMaker', type: TimelineMaker) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile sampleRate = project.marytts.voice.samplingRate idxIntervalInSeconds = 2.0 @@ -120,6 +134,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('makeWaveDatagrams', type: MakeWaveDatagrams) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile sampleRate = project.marytts.voice.samplingRate wavDir = project.wav.destDir @@ -128,6 +143,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('waveTimelineMaker', type: TimelineMaker) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile sampleRate = project.marytts.voice.samplingRate idxIntervalInSeconds = 0.1 @@ -136,6 +152,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('makeMcepDatagrams', type: MakeMcepDatagrams) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile sampleRate = project.marytts.voice.samplingRate mcepDir = project.mcepExtractor.destDir @@ -143,11 +160,13 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('generateMcepTimelineHeader', type: GenerateMcepTimelineHeader) { + group = 'MaryTTS Voicebuilding Legacy' srcDir = project.mcepExtractor.destDir destFile = project.legacyBuildDir.get().file('timeline_mcep.properties') } project.task('mcepTimelineMaker', type: McepTimelineMaker) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile headerFile = project.generateMcepTimelineHeader.destFile sampleRate = project.marytts.voice.samplingRate @@ -157,6 +176,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('phoneFeatureFileMaker', type: PhoneFeatureFileMaker) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile srcDir = project.phoneUnitFeatureComputer.destDir srcExt = project.phoneUnitFeatureComputer.outputExt @@ -166,6 +186,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('halfPhoneFeatureFileMaker', type: PhoneFeatureFileMaker) { + group = 'MaryTTS Voicebuilding Legacy' basenamesFile = project.basenames.destFile srcDir = project.halfPhoneUnitFeatureComputer.destDir srcExt = project.halfPhoneUnitFeatureComputer.outputExt @@ -175,6 +196,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('f0ContourFeatureFileMaker', type: F0ContourFeatureFileMaker) { + group = 'MaryTTS Voicebuilding Legacy' featureFile = project.halfPhoneFeatureFileMaker.destFile timelineFile = project.waveTimelineMaker.destFile unitFile = project.halfPhoneUnitFileMaker.destFile @@ -183,11 +205,13 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('generateAcousticFeatureDefinitionFile', type: GenerateAcousticFeatureDefinitionFile) { + group = 'MaryTTS Voicebuilding Legacy' srcFile = project.halfPhoneFeatureFileMaker.destFile destFile = project.legacyBuildDir.get().file('halfphoneUnitFeatureDefinition_ac.txt') } project.task('acousticFeatureFileMaker', type: AcousticFeatureFileMaker) { + group = 'MaryTTS Voicebuilding Legacy' featureDefinitionFile = project.generateAcousticFeatureDefinitionFile.destFile unitFile = project.halfPhoneUnitFileMaker.destFile contourFile = project.f0ContourFeatureFileMaker.destFile @@ -196,10 +220,12 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('generateJoinCostWeights', type: GenerateJoinCostWeights) { + group = 'MaryTTS Voicebuilding Legacy' destFile = project.legacyBuildDir.get().file('joinCostWeights.txt') } project.task('joinCostFileMaker', type: JoinCostFileMaker) { + group = 'MaryTTS Voicebuilding Legacy' weightsFile = project.generateJoinCostWeights.destFile mcepFile = project.mcepTimelineMaker.destFile unitFile = project.halfPhoneUnitFileMaker.destFile @@ -208,35 +234,41 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('generateFeatureSequence', type: GenerateFeatureSequence) { + group = 'MaryTTS Voicebuilding Legacy' features = ['phone'] destFile = project.legacyBuildDir.get().file('featureSequence.txt') } project.task('cartBuilder', type: CartBuilder) { + group = 'MaryTTS Voicebuilding Legacy' featureFile = project.acousticFeatureFileMaker.destFile featureSequenceFile = project.generateFeatureSequence.destFile destFile = project.legacyBuildDir.get().file('cart.mry') } project.task('generateDurationFeatureDescription', type: GenerateProsodyFeatureDescription) { + group = 'MaryTTS Voicebuilding Legacy' srcFile = project.phoneFeatureFileMaker.destFile targetFeatures = ['segment_duration'] destFile = project.layout.buildDirectory.dir('prosody').get().file('dur.desc') } project.task('generateF0FeatureDescription', type: GenerateProsodyFeatureDescription) { + group = 'MaryTTS Voicebuilding Legacy' srcFile = project.phoneFeatureFileMaker.destFile targetFeatures = ['leftF0', 'midF0', 'rightF0'] destFile = project.layout.buildDirectory.dir('prosody').get().file('f0.desc') } project.task('extractDurationFeatures', type: ExtractDurationFeatures) { + group = 'MaryTTS Voicebuilding Legacy' unitFile = project.phoneUnitFileMaker.destFile featureFile = project.phoneFeatureFileMaker.destFile destFile = project.layout.buildDirectory.dir('prosody').get().file('dur.feats') } project.task('extractF0Features', type: ExtractF0Features) { + group = 'MaryTTS Voicebuilding Legacy' unitFile = project.phoneUnitFileMaker.destFile featureFile = project.phoneFeatureFileMaker.destFile timelineFile = project.waveTimelineMaker.destFile @@ -244,6 +276,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('trainDurationCart', type: TrainProsodyCart) { + group = 'MaryTTS Voicebuilding Legacy' dataFile = project.extractDurationFeatures.destFile descriptionFile = project.generateDurationFeatureDescription.destFile predictee = 'segment_duration' @@ -251,6 +284,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('trainF0LeftCart', type: TrainProsodyCart) { + group = 'MaryTTS Voicebuilding Legacy' dataFile = project.extractF0Features.destFile descriptionFile = project.generateF0FeatureDescription.destFile predictee = 'leftF0' @@ -259,6 +293,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('trainF0MidCart', type: TrainProsodyCart) { + group = 'MaryTTS Voicebuilding Legacy' dataFile = project.extractF0Features.destFile descriptionFile = project.generateF0FeatureDescription.destFile predictee = 'midF0' @@ -267,6 +302,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('trainF0RightCart', type: TrainProsodyCart) { + group = 'MaryTTS Voicebuilding Legacy' dataFile = project.extractF0Features.destFile descriptionFile = project.generateF0FeatureDescription.destFile predictee = 'rightF0' @@ -275,24 +311,28 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('convertDurationCart', type: ConvertProsodyCart) { + group = 'MaryTTS Voicebuilding Legacy' srcFile = project.trainDurationCart.destFile featureFile = project.phoneFeatureFileMaker.destFile destFile = project.legacyBuildDir.get().file('dur.tree') } project.task('convertF0LeftCart', type: ConvertProsodyCart) { + group = 'MaryTTS Voicebuilding Legacy' srcFile = project.trainF0LeftCart.destFile featureFile = project.phoneFeatureFileMaker.destFile destFile = project.legacyBuildDir.get().file('f0.left.tree') } project.task('convertF0MidCart', type: ConvertProsodyCart) { + group = 'MaryTTS Voicebuilding Legacy' srcFile = project.trainF0MidCart.destFile featureFile = project.phoneFeatureFileMaker.destFile destFile = project.legacyBuildDir.get().file('f0.mid.tree') } project.task('convertF0RightCart', type: ConvertProsodyCart) { + group = 'MaryTTS Voicebuilding Legacy' srcFile = project.trainF0RightCart.destFile featureFile = project.phoneFeatureFileMaker.destFile destFile = project.legacyBuildDir.get().file('f0.right.tree') @@ -357,6 +397,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('processLegacyResources', type: Copy) { + group = 'MaryTTS Voicebuilding Legacy' from project.waveTimelineMaker, project.basenameTimelineMaker, project.halfPhoneUnitFileMaker, @@ -377,6 +418,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } def legacyZipTask = project.task('legacyZip', type: Zip) { + group = 'Publishing' from project.processLegacyResources from project.jar, { rename { "lib/$it" } @@ -385,6 +427,7 @@ class VoicebuildingLegacyPlugin implements Plugin { } project.task('legacyDescriptor', type: LegacyDescriptorTask) { + group = 'Publishing' srcFile = legacyZipTask.archiveFile def destFileName = legacyZipTask.archiveFileName.get() - '.zip' + '-component-descriptor.xml' destFile = project.distsDirectory.get().file(destFileName) @@ -402,15 +445,6 @@ class VoicebuildingLegacyPlugin implements Plugin { } } } - - project.afterEvaluate { - project.dependencies { - api "de.dfki.mary:marytts-lang-$project.marytts.voice.language:$project.marytts.version", { - exclude group: '*', module: 'groovy-all' - } - testImplementation "junit:junit:4.13" - } - } } } diff --git a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/F0ContourFeatureFileMaker.groovy b/src/main/groovy/de/dfki/mary/voicebuilding/tasks/F0ContourFeatureFileMaker.groovy index 56158aa1..75345bb2 100644 --- a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/F0ContourFeatureFileMaker.groovy +++ b/src/main/groovy/de/dfki/mary/voicebuilding/tasks/F0ContourFeatureFileMaker.groovy @@ -239,7 +239,9 @@ class F0ContourFeatureFileMaker extends DefaultTask { private List fitPolynomialsToSyllables(Sentence s, double[] logF0, int polynomOrder, UnitFileReader units) { List poly = new ArrayList(); for (Syllable syl : s) { + Pair syllableIndices = getSyllableIndicesInSentenceArray(s, syl, logF0.length, units); + double[] sylLogF0 = new double[syllableIndices.getSecond() - syllableIndices.getFirst()]; System.arraycopy(logF0, syllableIndices.getFirst(), sylLogF0, 0, sylLogF0.length); double[] coeffs = Polynomial.fitPolynomial(sylLogF0, polynomOrder); @@ -272,7 +274,10 @@ class F0ContourFeatureFileMaker extends DefaultTask { assert tsSylStart >= tsSentenceStart; long tsSylEnd = units.getUnit(syl.getLastUnitIndex()).startTime + units.getUnit(syl.getLastUnitIndex()).duration; assert tsSylEnd >= tsSylStart; - assert tsSylEnd <= tsSentenceEnd; + if (tsSylEnd > tsSentenceEnd) { + tsSylEnd = tsSentenceEnd; + } + // TODO: check if should be kept: assert tsSylEnd <= tsSentenceEnd; // Now map time to position in logF0 array: double factor = (double) arrayLength / (double) tsSentenceDuration; int iSylStart = (int) (factor * (tsSylStart - tsSentenceStart)); diff --git a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/FeatureListerTask.groovy b/src/main/groovy/de/dfki/mary/voicebuilding/tasks/FeatureListerTask.groovy index 3981d95b..fcc815de 100644 --- a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/FeatureListerTask.groovy +++ b/src/main/groovy/de/dfki/mary/voicebuilding/tasks/FeatureListerTask.groovy @@ -1,6 +1,7 @@ package de.dfki.mary.voicebuilding.tasks import org.gradle.api.DefaultTask +import org.gradle.api.JavaVersion import org.gradle.api.file.RegularFileProperty import org.gradle.api.tasks.OutputFile import org.gradle.api.tasks.TaskAction @@ -14,11 +15,18 @@ class FeatureListerTask extends DefaultTask { void generate() { project.javaexec { classpath project.configurations.marytts - main 'marytts.FeatureLister' + mainClass = 'marytts.FeatureLister' systemProperties = [ locale : project.marytts.voice.maryLocale, outputFile: destFile.get().asFile ] + if (JavaVersion.current().java9Compatible) { + jvmArgs = [ + '--add-opens', 'java.base/java.io=ALL-UNNAMED', + '--add-opens', 'java.base/java.lang=ALL-UNNAMED', + '--add-opens', 'java.base/java.util=ALL-UNNAMED' + ] + } } } } diff --git a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/GenerateServiceLoader.groovy b/src/main/groovy/de/dfki/mary/voicebuilding/tasks/GenerateServiceLoader.groovy deleted file mode 100644 index 09ca2359..00000000 --- a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/GenerateServiceLoader.groovy +++ /dev/null @@ -1,16 +0,0 @@ -package de.dfki.mary.voicebuilding.tasks - -import org.gradle.api.DefaultTask -import org.gradle.api.file.RegularFileProperty -import org.gradle.api.tasks.* - -class GenerateServiceLoader extends DefaultTask { - - @OutputFile - final RegularFileProperty destFile = project.objects.fileProperty() - - @TaskAction - void generate() { - destFile.get().asFile.text = "marytts.voice.${project.marytts.voice.nameCamelCase}.Config" - } -} diff --git a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/GenerateVoiceSource.groovy b/src/main/groovy/de/dfki/mary/voicebuilding/tasks/GenerateVoiceSource.groovy deleted file mode 100644 index 8da4f77b..00000000 --- a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/GenerateVoiceSource.groovy +++ /dev/null @@ -1,32 +0,0 @@ -package de.dfki.mary.voicebuilding.tasks - -import org.gradle.api.DefaultTask -import org.gradle.api.file.DirectoryProperty -import org.gradle.api.tasks.* - -class GenerateVoiceSource extends DefaultTask { - - @OutputDirectory - final DirectoryProperty testDirectory = project.objects.directoryProperty() - - @OutputDirectory - final DirectoryProperty integrationTestDirectory = project.objects.directoryProperty() - - @TaskAction - void generate() { - def engine = new groovy.text.GStringTemplateEngine() - def binding = [ project: project ] - - def templateStream = new InputStreamReader(getClass().getResourceAsStream('ConfigTest.java')) - def template = engine.createTemplate(templateStream).make(binding) - def configTestFile = new File(testDirectory.get().asFile, "${project.marytts.component.packagePath}/VoiceConfigTest.groovy") - configTestFile.parentFile.mkdirs() - configTestFile.text = template.toString() - - templateStream = new InputStreamReader(getClass().getResourceAsStream('LoadVoiceIT.groovy')) - template = engine.createTemplate(templateStream).make(binding) - def integrationTestFile = new File(integrationTestDirectory.get().asFile, "${project.marytts.component.packagePath}/LoadVoiceIT.groovy") - integrationTestFile.parentFile.mkdirs() - integrationTestFile.text = template.toString() - } -} diff --git a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/MaryInterfaceBatchTask.groovy b/src/main/groovy/de/dfki/mary/voicebuilding/tasks/MaryInterfaceBatchTask.groovy index 216732a1..b28946c0 100644 --- a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/MaryInterfaceBatchTask.groovy +++ b/src/main/groovy/de/dfki/mary/voicebuilding/tasks/MaryInterfaceBatchTask.groovy @@ -2,6 +2,7 @@ package de.dfki.mary.voicebuilding.tasks import groovy.json.JsonBuilder import org.gradle.api.DefaultTask +import org.gradle.api.JavaVersion import org.gradle.api.file.DirectoryProperty import org.gradle.api.file.RegularFileProperty import org.gradle.api.provider.ListProperty @@ -66,9 +67,16 @@ class MaryInterfaceBatchTask extends DefaultTask { batchFile.text = new JsonBuilder(batch).toPrettyString() project.javaexec { classpath project.configurations.marytts - main 'marytts.BatchProcessor' + mainClass = 'marytts.BatchProcessor' args batchFile systemProperties << maryttsProperties.getOrElse([:]) + if (JavaVersion.current().java9Compatible) { + jvmArgs = [ + '--add-opens', 'java.base/java.io=ALL-UNNAMED', + '--add-opens', 'java.base/java.lang=ALL-UNNAMED', + '--add-opens', 'java.base/java.util=ALL-UNNAMED' + ] + } } } } diff --git a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/PhoneUnitFileMaker.groovy b/src/main/groovy/de/dfki/mary/voicebuilding/tasks/PhoneUnitFileMaker.groovy index 76f85fff..f0fa0d48 100644 --- a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/PhoneUnitFileMaker.groovy +++ b/src/main/groovy/de/dfki/mary/voicebuilding/tasks/PhoneUnitFileMaker.groovy @@ -36,27 +36,40 @@ class PhoneUnitFileMaker extends DefaultTask { def out = new DataOutputStream(baos) def utteranceEndSample = 0 def numUnits = 0 + basenamesFile.get().asFile.eachLine('UTF-8') { basename -> def pmFile = pmDir.file("${basename}.pm").get().asFile def pm = new ESTTrackReader(pmFile.path) + + // Insert start edge out.writeLong(utteranceEndSample) out.writeInt(-1) numUnits++ + def srcFile = srcDir.file("${basename}.${srcExt.get()}").get().asFile def unitStartSample = 0 labSerializer.fromString(srcFile.text).tiers[0].annotations.each { segment -> def unitEndTime = pm.getClosestTime(segment.end) def unitEndSample = (unitEndTime * sampleRate.get()) as long def unitNumSamples = unitEndSample - unitStartSample - // TODO: skip units with zero duration - out.writeLong(utteranceEndSample + unitStartSample) - out.writeInt(unitNumSamples as int) - unitStartSample = unitEndSample - numUnits++ + if (unitNumSamples > 0) { + out.writeLong(utteranceEndSample + unitStartSample) + out.writeInt(unitNumSamples as int) + unitStartSample = unitEndSample + numUnits++ + } else { // skip units with zero duration + println("$basename, $segment => ${unitNumSamples}") + out.writeLong(utteranceEndSample + unitStartSample) + out.writeInt(unitNumSamples as int) + unitStartSample = unitEndSample + numUnits++ + } } + out.writeLong(utteranceEndSample + unitStartSample) out.writeInt(-1) numUnits++ + def utteranceEndTime = pm.timeSpan utteranceEndSample += (utteranceEndTime * sampleRate.get()) as long } diff --git a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/ProcessPhoneLabels.groovy b/src/main/groovy/de/dfki/mary/voicebuilding/tasks/ProcessPhoneLabels.groovy index 3d33d880..bf221f2c 100644 --- a/src/main/groovy/de/dfki/mary/voicebuilding/tasks/ProcessPhoneLabels.groovy +++ b/src/main/groovy/de/dfki/mary/voicebuilding/tasks/ProcessPhoneLabels.groovy @@ -28,17 +28,21 @@ class ProcessPhoneLabels extends DefaultTask { basenamesFile.get().asFile.eachLine('UTF-8') { basename -> def srcFile = srcDir.file("${basename}.lab").get().asFile def phoneTier = labSerializer.fromString(srcFile.getText('UTF-8')).tiers.first() + + // merge duplicate pauses def phoneIterator = phoneTier.annotations.listIterator() def phone = phoneIterator.next() while (phoneIterator.hasNext()) { def nextPhone = phoneIterator.next() - // merge duplicate pauses if (phone.text == nextPhone.text && phone.text == '_') { phone.end = nextPhone.end phoneIterator.remove() } + phone = nextPhone } + + destDir.file("${basename}.lab").get().asFile.withWriter('UTF-8') { dest -> def textGrid = new TextGrid(phoneTier.start, phoneTier.end, [phoneTier]) dest << labSerializer.toString(textGrid, tierName) diff --git a/src/main/resources/de/dfki/mary/voicebuilding/tasks/LoadVoiceIT.groovy b/src/main/resources/de/dfki/mary/tasks/LoadVoiceIT.groovy similarity index 100% rename from src/main/resources/de/dfki/mary/voicebuilding/tasks/LoadVoiceIT.groovy rename to src/main/resources/de/dfki/mary/tasks/LoadVoiceIT.groovy diff --git a/src/main/resources/de/dfki/mary/voicebuilding/tasks/ConfigTest.java b/src/main/resources/de/dfki/mary/tasks/VoiceConfigTest.java similarity index 100% rename from src/main/resources/de/dfki/mary/voicebuilding/tasks/ConfigTest.java rename to src/main/resources/de/dfki/mary/tasks/VoiceConfigTest.java diff --git a/src/test/groovy/de/dfki/mary/voicebuilding/BasePluginFunctionalTest.groovy b/src/test/groovy/de/dfki/mary/voicebuilding/BasePluginFunctionalTest.groovy index 8ea180c1..be1ce1eb 100644 --- a/src/test/groovy/de/dfki/mary/voicebuilding/BasePluginFunctionalTest.groovy +++ b/src/test/groovy/de/dfki/mary/voicebuilding/BasePluginFunctionalTest.groovy @@ -16,6 +16,7 @@ class BasePluginFunctionalTest { @BeforeSuite void setup() { def projectDir = File.createTempDir() + new File(projectDir, 'settings.gradle').createNewFile() gradle = GradleRunner.create() .withProjectDir(projectDir) @@ -53,10 +54,8 @@ class BasePluginFunctionalTest { ['testVoiceProps', false], ['testJavaCompatibility', false], ['generateConfig', false], - ['generateVoiceSource', false], - // ['compileTestJava', true], - ['compileGroovy', true], - // NOTE: no need for now, but in case it is needed for the future ['compileJava', true], + ['compileJava', true], + ['compileTestGroovy', true], ['compileIntegrationTestGroovy', true], ['testGeneratePomFileForMavenJavaPublication', false], ['generatePomProperties', true], diff --git a/src/test/groovy/de/dfki/mary/voicebuilding/DataPluginFunctionalTest.groovy b/src/test/groovy/de/dfki/mary/voicebuilding/DataPluginFunctionalTest.groovy index baf44c53..0b37b4f9 100644 --- a/src/test/groovy/de/dfki/mary/voicebuilding/DataPluginFunctionalTest.groovy +++ b/src/test/groovy/de/dfki/mary/voicebuilding/DataPluginFunctionalTest.groovy @@ -16,6 +16,7 @@ class DataPluginFunctionalTest { @BeforeSuite void setup() { def projectDir = File.createTempDir() + new File(projectDir, 'settings.gradle').createNewFile() gradle = GradleRunner.create() .withProjectDir(projectDir) diff --git a/src/test/groovy/de/dfki/mary/voicebuilding/FestvoxPluginFunctionalTest.groovy b/src/test/groovy/de/dfki/mary/voicebuilding/FestvoxPluginFunctionalTest.groovy index 173b4e41..74b301ed 100644 --- a/src/test/groovy/de/dfki/mary/voicebuilding/FestvoxPluginFunctionalTest.groovy +++ b/src/test/groovy/de/dfki/mary/voicebuilding/FestvoxPluginFunctionalTest.groovy @@ -16,6 +16,7 @@ class FestvoxPluginFunctionalTest { @BeforeSuite void setup() { def projectDir = File.createTempDir() + new File(projectDir, 'settings.gradle').createNewFile() gradle = GradleRunner.create() .withProjectDir(projectDir) diff --git a/src/test/groovy/de/dfki/mary/voicebuilding/LegacyPluginFunctionalTest.groovy b/src/test/groovy/de/dfki/mary/voicebuilding/LegacyPluginFunctionalTest.groovy index ccc2636f..ca9cfb10 100644 --- a/src/test/groovy/de/dfki/mary/voicebuilding/LegacyPluginFunctionalTest.groovy +++ b/src/test/groovy/de/dfki/mary/voicebuilding/LegacyPluginFunctionalTest.groovy @@ -16,6 +16,7 @@ class LegacyPluginFunctionalTest { @BeforeSuite void setup() { def projectDir = File.createTempDir() + new File(projectDir, 'settings.gradle').createNewFile() gradle = GradleRunner.create() .withProjectDir(projectDir) diff --git a/src/test/groovy/de/dfki/mary/voicebuilding/LegacyPluginLegacyGradleTest.groovy b/src/test/groovy/de/dfki/mary/voicebuilding/LegacyPluginLegacyGradleTest.groovy index ff5a6f36..184f171b 100644 --- a/src/test/groovy/de/dfki/mary/voicebuilding/LegacyPluginLegacyGradleTest.groovy +++ b/src/test/groovy/de/dfki/mary/voicebuilding/LegacyPluginLegacyGradleTest.groovy @@ -13,6 +13,7 @@ class LegacyPluginLegacyGradleTest { @BeforeSuite void setup() { def projectDir = File.createTempDir() + new File(projectDir, 'settings.gradle').createNewFile() gradle = GradleRunner.create() .withProjectDir(projectDir) .withPluginClasspath() @@ -25,14 +26,14 @@ class LegacyPluginLegacyGradleTest { } @Test - void 'Gradle v6-1 cannot apply plugin'() { - gradle.withGradleVersion('6.1').buildAndFail() + void 'Gradle v6-9 cannot apply plugin'() { + gradle.withGradleVersion('6.9').buildAndFail() } @Test - void 'Gradle v6-2 can apply plugin'() { - if (JavaVersion.current() > JavaVersion.VERSION_13) - throw new SkipException('Gradle v6.2 does not support Java versions higher than 13') - gradle.withGradleVersion('6.2').build() + void 'Gradle v7-0 can apply plugin'() { + if (JavaVersion.current() > JavaVersion.VERSION_16) + throw new SkipException('Gradle v7.0 does not support Java versions higher than 16') + gradle.withGradleVersion('7.0').build() } } diff --git a/src/test/groovy/de/dfki/mary/voicebuilding/LegacyPluginOneShotFunctionalTest.groovy b/src/test/groovy/de/dfki/mary/voicebuilding/LegacyPluginOneShotFunctionalTest.groovy index 0c7cde27..c33e3778 100644 --- a/src/test/groovy/de/dfki/mary/voicebuilding/LegacyPluginOneShotFunctionalTest.groovy +++ b/src/test/groovy/de/dfki/mary/voicebuilding/LegacyPluginOneShotFunctionalTest.groovy @@ -14,6 +14,7 @@ class LegacyPluginOneShotFunctionalTest { @BeforeSuite void setup() { def projectDir = File.createTempDir() + new File(projectDir, 'settings.gradle').createNewFile() gradle = GradleRunner.create() .withProjectDir(projectDir) diff --git a/src/test/groovy/de/dfki/mary/voicebuilding/tasks/GenerateBasenamesListFunctionalTest.groovy b/src/test/groovy/de/dfki/mary/voicebuilding/tasks/GenerateBasenamesListFunctionalTest.groovy index 9825a88b..94cf9a76 100644 --- a/src/test/groovy/de/dfki/mary/voicebuilding/tasks/GenerateBasenamesListFunctionalTest.groovy +++ b/src/test/groovy/de/dfki/mary/voicebuilding/tasks/GenerateBasenamesListFunctionalTest.groovy @@ -8,7 +8,7 @@ class GenerateBasenamesListFunctionalTest { @Test void 'Given data directories, When basenames list is generated, Then basenames are in sort order'() { - def projectDir = File.createTempDir() + def projectDir = createProjectDirWithSettingsFile() def basenames = generateBasenames(5) createDataDirectories(projectDir, basenames) @@ -23,7 +23,7 @@ class GenerateBasenamesListFunctionalTest { @Test void 'Given data directories with some missing files, When basenames list is generated, Then basenames exclude them'() { - def projectDir = File.createTempDir() + def projectDir = createProjectDirWithSettingsFile() def basenames = generateBasenames(6) createDataDirectories(projectDir, basenames) @@ -42,7 +42,7 @@ class GenerateBasenamesListFunctionalTest { @Test void 'Given data directories, When custom list is provided, Then basenames are in custom order'() { - def projectDir = File.createTempDir() + def projectDir = createProjectDirWithSettingsFile() def basenames = generateBasenames(5) createDataDirectories(projectDir, basenames) @@ -65,7 +65,7 @@ class GenerateBasenamesListFunctionalTest { @Test void 'Given data directories, When custom list with comments is provided, Then basenames are in custom order'() { - def projectDir = File.createTempDir() + def projectDir = createProjectDirWithSettingsFile() def basenames = generateBasenames(5) createDataDirectories(projectDir, basenames) @@ -91,7 +91,7 @@ class GenerateBasenamesListFunctionalTest { @Test void 'Given data directories with some missing files, When custom list is provided, Then basenames exclude them and are in custom order'() { - def projectDir = File.createTempDir() + def projectDir = createProjectDirWithSettingsFile() def basenames = generateBasenames(6) createDataDirectories(projectDir, basenames) @@ -116,6 +116,12 @@ class GenerateBasenamesListFunctionalTest { assert expected == actual } + private static File createProjectDirWithSettingsFile() { + def projectDir = File.createTempDir() + new File(projectDir, 'settings.gradle').createNewFile() + projectDir + } + private static List generateBasenames(int n) { (1..n).collect { i -> String.format('test_%04d', i) diff --git a/src/test/resources/de/dfki/mary/voicebuilding/basePluginFunctionalTestBuildScript.gradle b/src/test/resources/de/dfki/mary/voicebuilding/basePluginFunctionalTestBuildScript.gradle index 3a936abf..37626698 100644 --- a/src/test/resources/de/dfki/mary/voicebuilding/basePluginFunctionalTestBuildScript.gradle +++ b/src/test/resources/de/dfki/mary/voicebuilding/basePluginFunctionalTestBuildScript.gradle @@ -1,6 +1,6 @@ buildscript { repositories { - jcenter() + mavenCentral() } dependencies { classpath group: 'xmlunit', name: 'xmlunit', version: '1.6' @@ -54,31 +54,27 @@ task testJavaCompatibility(group: 'Verification') { } } -task testGenerateVoiceSource(group: 'Verification') { - dependsOn generateSource +task testCompileJava(group: 'Verification') { + dependsOn compileJava doLast { - // TODO: assert file("$buildDir/generatedSrc/main/java/marytts/voice/$marytts.voice.nameCamelCase/Config.java").exists() - } -} - -task testCompileGroovy(group: 'Verification') { - dependsOn compileGroovy - doLast { - assert file("$buildDir/classes/groovy/main/marytts/voice/$marytts.voice.nameCamelCase/${marytts.voice.nameCamelCase}Config.class").exists() + assert fileTree(sourceSets.main.java.classesDirectory) + .contains(file("$buildDir/classes/java/main/marytts/voice/$marytts.voice.nameCamelCase/${marytts.voice.nameCamelCase}Config.class")) } } task testCompileTestGroovy(group: 'Verification') { dependsOn compileTestGroovy doLast { - assert file("$buildDir/classes/groovy/test/marytts/voice/$marytts.voice.nameCamelCase/ConfigTest.class").exists() + assert fileTree(sourceSets.test.groovy.classesDirectory) + .contains(file("$buildDir/classes/groovy/test/marytts/voice/$marytts.voice.nameCamelCase/VoiceConfigTest.class")) } } task testCompileIntegrationTestGroovy(group: 'Verification') { dependsOn compileIntegrationTestGroovy doLast { - assert file("$buildDir/classes/groovy/integrationTest/marytts/voice/$marytts.voice.nameCamelCase/LoadVoiceIT.class").exists() + assert fileTree(sourceSets.integrationTest.groovy.classesDirectory) + .contains(file("$buildDir/classes/groovy/integrationTest/marytts/voice/$marytts.voice.nameCamelCase/LoadVoiceIT.class")) } } @@ -128,7 +124,7 @@ task testGeneratePomFileForMavenJavaPublication(group: 'Verification') { def pomXml = new groovy.xml.StreamingMarkupBuilder().bind { project(xmlns: "http://maven.apache.org/POM/4.0.0", 'xmlns:xsi': "http://www.w3.org/2001/XMLSchema-instance", - 'xsi:schemaLocation': "http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd") { + 'xsi:schemaLocation': "http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd") { modelVersion '4.0.0' groupId project.group artifactId projectDir.name @@ -147,6 +143,14 @@ task testGeneratePomFileForMavenJavaPublication(group: 'Verification') { delegate.version maryVersion scope 'compile' exclusions { + exclusion { + artifactId 'Jampack' + groupId 'gov.nist.math' + } + exclusion { + artifactId 'fast-md5' + groupId 'com.twmacinta' + } exclusion { artifactId 'groovy-all' groupId '*' @@ -159,6 +163,14 @@ task testGeneratePomFileForMavenJavaPublication(group: 'Verification') { delegate.version maryVersion scope 'runtime' exclusions { + exclusion { + artifactId 'Jampack' + groupId 'gov.nist.math' + } + exclusion { + artifactId 'fast-md5' + groupId 'com.twmacinta' + } exclusion { artifactId 'groovy-all' groupId '*' diff --git a/src/test/resources/de/dfki/mary/voicebuilding/legacyPluginFunctionalTestBuildScript.gradle b/src/test/resources/de/dfki/mary/voicebuilding/legacyPluginFunctionalTestBuildScript.gradle index 449c1efd..01257a14 100644 --- a/src/test/resources/de/dfki/mary/voicebuilding/legacyPluginFunctionalTestBuildScript.gradle +++ b/src/test/resources/de/dfki/mary/voicebuilding/legacyPluginFunctionalTestBuildScript.gradle @@ -1,6 +1,6 @@ buildscript { repositories { - jcenter() + mavenCentral() } dependencies { classpath group: 'xmlunit', name: 'xmlunit', version: '1.6'