Switch from for loop to foreach
This commit is contained in:
parent
8f1b65a4d2
commit
32780c05bd
12
main.js
12
main.js
|
@ -117,12 +117,12 @@ async function main() {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (targetArchitectures.length != 0) {
|
if (targetArchitectures.length != 0) {
|
||||||
for (targetArchitecture in targetArchitectures) {
|
targetArchitectures.forEach(targetArchitecture => {
|
||||||
runDockerExecStep(
|
runDockerExecStep(
|
||||||
"Add target architecture: " + targetArchitecture,
|
"Add target architecture: " + targetArchitecture,
|
||||||
["dpkg", "--add-architecture", targetArchitecture]
|
["dpkg", "--add-architecture", targetArchitecture]
|
||||||
)
|
)
|
||||||
}
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
runDockerExecStep(
|
runDockerExecStep(
|
||||||
|
@ -139,9 +139,9 @@ async function main() {
|
||||||
]
|
]
|
||||||
|
|
||||||
// Used by pybuild
|
// Used by pybuild
|
||||||
for (targetArchitecture in targetArchitectures) {
|
targetArchitectures.forEach(targetArchitecture => {
|
||||||
devPackages.concat("libpython3.7-minimal:" + targetArchitecture)
|
devPackages.concat("libpython3.7-minimal:" + targetArchitecture)
|
||||||
}
|
})
|
||||||
|
|
||||||
return devPackages
|
return devPackages
|
||||||
}
|
}
|
||||||
|
@ -157,7 +157,7 @@ async function main() {
|
||||||
["apt-get", "build-dep", "-y", sourceDirectory]
|
["apt-get", "build-dep", "-y", sourceDirectory]
|
||||||
)
|
)
|
||||||
|
|
||||||
for (targetArchitecture in targetArchitectures) {
|
targetArchitectures.forEach(targetArchitecture => {
|
||||||
runDockerExecStep(
|
runDockerExecStep(
|
||||||
"Build package for architecture: " + targetArchitecture,
|
"Build package for architecture: " + targetArchitecture,
|
||||||
[
|
[
|
||||||
|
@ -165,7 +165,7 @@ async function main() {
|
||||||
"-a" + targetArchitecture
|
"-a" + targetArchitecture
|
||||||
].concat(dpkgBuildPackageOpts)
|
].concat(dpkgBuildPackageOpts)
|
||||||
)
|
)
|
||||||
}
|
})
|
||||||
|
|
||||||
runDockerExecStep(
|
runDockerExecStep(
|
||||||
"Run static analysis",
|
"Run static analysis",
|
||||||
|
|
Loading…
Reference in a new issue