NativeScript can't find Android SDK on Mac OS

前端 未结 2 787
庸人自扰
庸人自扰 2021-01-07 03:35

I\'ve installed NativeScript and I try to do tns platform add android but it doesn\'t work. ANDROID_HOME path is correct and I have installed SDK (API 22 and th

2条回答
  •  旧巷少年郎
    2021-01-07 04:08

    I solved this using the SDK manager in Android Studio, having already installed it previously, install all the requirements, namely

    tools,platform-tools,android-25,build-tools-25.0.2,extra-android-m2repository,extra-google-m2repository,extra-android-support
    

    Once installed change your ANDROID_HOME environment variable to point to this SDK manager. Typically, it will be at (/Users//Library/Android/sdk)

    export ANDROID_HOME=/Users//Library/Android/sdk
    

    Confirm that NativeScript detects your changes by running

    tns doctor
    

提交回复
热议问题