interop-testing: Fix script rewrite for Gradle 7.2

e0dca93c broke the interop-testing script for unix because Gradle
changed the scripts for
https://github.com/gradle/gradle/security/advisories/GHSA-6j2p-252f-7mw8

The solution here looks weird, but we are inserting the replacement
string into a single-quoted string, so we stop that string, start a
double-quoted string to allow the variable replacement, and then resume
the previous string.
This commit is contained in:
Eric Anderson 2022-01-11 09:43:41 -08:00 committed by GitHub
parent 56e9321d8a
commit 69671e152f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -76,7 +76,7 @@ task test_client(type: CreateStartScripts) {
outputDir = new File(project.buildDir, 'tmp/scripts/' + name)
classpath = startScripts.classpath
doLast {
unixScript.text = unixScript.text.replace('JAVAAGENT_APP_HOME', '\$APP_HOME/lib/')
unixScript.text = unixScript.text.replace('JAVAAGENT_APP_HOME', '\'"\$APP_HOME"\'/lib/')
windowsScript.text = windowsScript.text.replace('JAVAAGENT_APP_HOME', '%APP_HOME%\\lib\\')
}
}