Skip to content

Commit 3e463fa

Browse files
committed
use .add instead of .push to arrays in gradle
1 parent cdb6a29 commit 3e463fa

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

test-app/app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -509,7 +509,7 @@ afterEvaluate { project ->
509509
}.artifacts.each {
510510
def jar = it.file;
511511
if (!jars.contains(jar)) {
512-
jars.push(jar)
512+
jars.add(jar)
513513
def destDir = md5(jar.path);
514514
def outputDir = new File(Paths.get(extractedDependenciesDir, destDir).normalize().toString())
515515

@@ -543,7 +543,7 @@ afterEvaluate { project ->
543543
// }
544544
}
545545
}
546-
allJars.push([file: jar, outputDir: outputDir])
546+
allJars.add([file: jar, outputDir: outputDir])
547547
}
548548
}
549549
}

test-app/runtests.gradle

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,14 @@ def getBuildArguments = { ->
2828
if (isWinOs) {
2929
arguments += ["cmd", "/c", "gradlew"]
3030
} else {
31-
arguments.push("./gradlew")
31+
arguments.add("./gradlew")
3232
}
33-
arguments.push(":app:installDebug")
33+
arguments.add(":app:installDebug")
3434
if (onlyX86) {
35-
arguments.push("-PonlyX86")
35+
arguments.add("-PonlyX86")
3636
}
3737
if (useCCache) {
38-
arguments.push("-PuseCCache")
38+
arguments.add("-PuseCCache")
3939
}
4040
return arguments
4141
}

test-app/runtime/build.gradle

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,15 +54,15 @@ android {
5454
externalNativeBuild {
5555
cmake {
5656
if (optimized) {
57-
arguments.push("-DOPTIMIZED_BUILD=true")
57+
arguments.add("-DOPTIMIZED_BUILD=true")
5858
}
5959

6060
if (optimizedWithInspector) {
61-
arguments.push("-DOPTIMIZED_WITH_INSPECTOR_BUILD=true")
61+
arguments.add("-DOPTIMIZED_WITH_INSPECTOR_BUILD=true")
6262
}
6363

6464
if (useCCache) {
65-
arguments.push("-DUSE_CCACHE=true")
65+
arguments.add("-DUSE_CCACHE=true")
6666
}
6767

6868
//https://developer.android.com/ndk/guides/cmake.html

0 commit comments

Comments
 (0)