Error: Could not find gradle wrapper within Android SDK. Might need to update your Android SDK - And

在Windows7上運行 「cordova build android」 報錯,以下:android

C:\test\hello> cordova build android
ANDROID_HOME=C:\Users\kongxx\AppData\Local\Android\sdk
JAVA_HOME=C:\Program Files\Java\jdk1.8.0_121
Error: Could not find gradle wrapper within Android SDK. Might need to update your Android SDK.

解決辦法:windows

1.若是已經安裝了Android Studio:app

  • 複製templates目錄:C:\Program Files\Android\Android Studio\plugins\android\lib\templates
  • 粘貼至以下目錄:C:\Users\<user-name>\AppData\Local\Android\sdk\tools

2.沒有安裝Android Studio:gradle

相關文章
相關標籤/搜索