mirror of
https://github.com/apache/cordova-android.git
synced 2025-03-29 02:12:50 +08:00
fix: copy gradle wrapper from tools to platform root dir (#1781)
This commit is contained in:
parent
aad36fe565
commit
ff11f659f0
@ -18,6 +18,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
const fs = require('node:fs');
|
const fs = require('node:fs');
|
||||||
|
const fsp = require('node:fs/promises');
|
||||||
const path = require('node:path');
|
const path = require('node:path');
|
||||||
const execa = require('execa');
|
const execa = require('execa');
|
||||||
const glob = require('fast-glob');
|
const glob = require('fast-glob');
|
||||||
@ -289,6 +290,10 @@ class ProjectBuilder {
|
|||||||
.then(function () {
|
.then(function () {
|
||||||
events.emit('verbose', `Using Gradle: ${config.GRADLE_VERSION}`);
|
events.emit('verbose', `Using Gradle: ${config.GRADLE_VERSION}`);
|
||||||
return self.installGradleWrapper(config.GRADLE_VERSION);
|
return self.installGradleWrapper(config.GRADLE_VERSION);
|
||||||
|
}).then(async function () {
|
||||||
|
await fsp.cp(path.join(self.root, 'tools', 'gradle'), path.join(self.root, 'gradle'), { recursive: true, force: true });
|
||||||
|
await fsp.cp(path.join(self.root, 'tools', 'gradlew'), path.join(self.root, 'gradlew'), { recursive: true, force: true });
|
||||||
|
await fsp.cp(path.join(self.root, 'tools', 'gradlew.bat'), path.join(self.root, 'gradlew.bat'), { recursive: true, force: true });
|
||||||
}).then(function () {
|
}).then(function () {
|
||||||
return self.prepBuildFiles();
|
return self.prepBuildFiles();
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user