Print

Ionic解决Could not read build file capacitor/build.gradle as it does notexist.问题


作者: 文章来源:

本文原地址:https://www.mimiwuqi.com/webqianduan/196450.html

Ionic 项目以前运行的好好的,今天编译 android 突然出现以下报错。

A problem occured configuring project ':capacitor android'.
> Could not read build file '/Users/ado/my/work/h5/ionic_demo/node_modules/@capacitor/android/capacitor/build.gradle' as it does not exist.

* Try:
Run with --info or --debug option to get more log output. Run with --scan to get full insigns.

* Exception is:
org.gradle.api.ProjectConfigurationException: A problem occured configuring project ':capacitor android'.<1111 internal calls>
Caused by: org.gradle.api.resource.MissingResourceException: Could not read build file '/Users/ado/my/work/h5/ionic_demo/node_modules/@capacitor/android/capacitor/build.gradle' as it does not exist.
	...107 more

解决办法

首先检查 node_module 中的 android 模块的build.gradle是否存在,如果确实存在,只能重新生成。

Ionic解决Could not read build file capacitor/build.gradle as it does notexist.问题 1

更多 建站教程 请访问 https://www.mimiwuqi.com/webqianduan/