错误日志:

  • What went wrong:
    A problem occurred configuring root project ‘android’.

    The SDK directory ‘C:\Users\Administrator\AppData\Local\Android\sdk’ does not exist.

  • Try:
    Run with –stacktrace option to get the stack trace. Run with –info or –debug option to get more log output.

Error: cmd: Command failed with exit code 1 Error output:
FAILURE: Build failed with an exception.

  • What went wrong:
    A problem occurred configuring root project ‘android’.

    The SDK directory ‘C:\Users\Administrator\AppData\Local\Android\sdk’ does not exist.

  • Try:
    Run with –stacktrace option to get the stack trace. Run with –info or –debug option to get more log output.


解决方案:

ionic2 打包android包时报'C:\Users\Administrator\AppData\Local\Android\sdk' does not exist.

找到如图中的local.prooerties文件,将下图的sdk换成你的本地SDK的位置即可。
注意:如果没有这个文件编译时会报另一种错误,大概就是说没有可用的SDK,这时要去找个local.prooerties文件拷贝到图中目录下(自己新建一个这样的文件也行),然后再将你本地的SDK地址添加进来,还要注意,路径中的使用的是反斜杠 \ ,我有次就掉进了这个坑里!!!
ionic2 打包android包时报'C:\Users\Administrator\AppData\Local\Android\sdk' does not exist.


为了能及时的将自己踩到的前端坑(包括ionic,angular,ReactNative,小程序,APICloud)分享给大家,以后会逐渐将文章转移到微信公众号:前端e家(front_e_family)。可直接扫码关注,公众号会不定期更新新文章,分享踩坑笔记!期待您的关注!
ionic2 打包android包时报'C:\Users\Administrator\AppData\Local\Android\sdk' does not exist.

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-10-05
  • 2021-10-10
  • 2021-08-04
  • 2021-10-21
猜你喜欢
  • 2022-01-12
  • 2022-12-23
  • 2021-08-09
  • 2022-01-25
  • 2022-12-23
  • 2021-12-11
  • 2022-12-23
相关资源
相似解决方案