所以在我刚刚改变我的设备之前,当我试图运行live reloaded时,我的ionic项目工作得很好。我想我已经安装了所有与我的旧设备相同版本的jdk和node js。
现在,我已经得到这个错误,当我试图运行离子帽运行android -l -外部
[capacitor] × Running Gradle build - failed!
[capacitor] [error]
[capacitor] FAILURE: Build failed with an exception.
[capacitor]
[capacitor] * What went wrong:
[capacitor] Could not initialize class org.codehaus.groovy.runtime.InvokerHelper
[capacitor] > Exception java.lang.NoClassDefFoundError: Could not initialize class org.codehaus.groovy.reflection.ReflectionCache
[in thread "Daemon worker"]
[capacitor]
[capacitor] * Try:
[capacitor] Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run wi
th --scan to get full insights.
[capacitor]
[capacitor] * Get more help at https://help.gradle.org
[capacitor]
[capacitor] BUILD FAILED in 1s
[capacitor]
[ERROR] An error occurred while running subprocess capacitor.
我一直在寻找答案,但大多数情况下,他们告诉我更改这行代码
distributionUrl=https\://services.gradle.org/distributions/gradle-6.1.1-all.zip
但是它只是给了我另一个错误。我试着把它改成其他版本。但是仍然不起作用。
我希望我的离子应用程序将能够运行livereload。
1条答案
按热度按时间moiiocjp1#
我通过在我的www.example.com中添加以下行来解决此问题gradle.properties