ami*_*eli 6 android cordova google-cloud-messaging ionic
我尝试为Android构建一个离子应用程序,我有这个错误:
What went wrong:
A problem occurred configuring root project 'android'.
> Could not resolve all dependencies for configuration ':_debugCompile'.
> Could not find any version that matches com.android.support:support-v4:+.
Searched in the following locations:
https://repo1.maven.org/maven2/com/android/support/support-v4/maven-metadata.xml
https://repo1.maven.org/maven2/com/android/support/support-v4/
Required by:
:android:unspecified
Run Code Online (Sandbox Code Playgroud)
安装Android支持库和Android支持存储库.
谢谢您帮忙
编辑:
我尝试更新cordova和cordova-cli,但它没有用.
该位置https://repo1.maven.org/maven2/com/android/support/不再存在(404).所以maven配置似乎是个问题.
我发现了一个关于你遇到的同样问题的GitHub问题,它通过运行更新SDK(你已经做过)并将Android平台读入Ionic项目来解决:
# Update Android SDK
android list sdk
android update sdk --no-ui --filter extra
# Refresh Ionic Android configuration
ionic platform remove android
ionic platform add android
Run Code Online (Sandbox Code Playgroud)