Cordova build changes distributionUrl in gradle-wrapper.properties file

后端 未结 8 1232
小鲜肉
小鲜肉 2020-12-05 06:30

I keep getting the following build exception when I run

 cordova run android --verbose
  • What went wrong: A problem occurred evaluatin
8条回答
  •  我在风中等你
    2020-12-05 07:09

    Inside platforms/android/cordova/lib/builders/ProjectBuilder.js

    around line 232 you will see:

    var distributionUrl = process.env['CORDOVA_ANDROID_GRADLE_DISTRIBUTION_URL'] || 'https\://services.gradle.org/distributions/gradle-4.10.3-all.zip';

    adjust the gradle to whatever you need.

    Example: var distributionUrl = process.env['CORDOVA_ANDROID_GRADLE_DISTRIBUTION_URL'] || 'https\://services.gradle.org/distributions/gradle-5.4.1-all.zip';

提交回复
热议问题