繁体   English   中英

安装Nativescript:Cocoapods出错

[英]Installing Nativescript: Error with Cocoapods

我正在尝试在我的Mac上安装Nativescript(运行OS Sierra)。 我正如网站所说的那样做,我试图在任何地方搜索我能找到解决方案但没有运气。

我在开始时得到了一些不赞成的警告,但是当它到达Cocoapods时,一切都真的开始流失了。

这是终端上的内容(抱歉发布了整个内容,但也许还有其他错误,我没有注意到):

Theos-MacBook-Pro:/ theobalestra$ brew install xcproj
Warning: xcproj-0.2.1 already installed
Theos-MacBook-Pro:/ theobalestra$ npm i -g nativescript
npm WARN deprecated node-uuid@1.4.7: Use uuid module instead
npm WARN deprecated lodash-node@2.4.1: This package is discontinued.                 Use lodash@^4.0.0.
npm WARN deprecated node-uuid@1.3.3: Use uuid module instead

> nativescript@3.0.1 preuninstall /Users/theobalestra/.npm-    packages/lib/node_modules/nativescript
> node preuninstall.js

Failed to complete all pre-uninstall steps.
/Users/theobalestra/.npm-packages/bin/nativescript ->     /Users/theobalestra/.npm-packages/lib/node_modules/nativescript/bin/tns
/Users/theobalestra/.npm-packages/bin/tns -> /Users/theobalestra/.npm-    packages/lib/node_modules/nativescript/bin/tns

> nativescript@3.0.1 postinstall /Users/theobalestra/.npm-    packages/lib/node_modules/nativescript
> node postinstall.js

WARNING: adb from the Android SDK is not installed or is not configured     properly.
For Android-related operations, the NativeScript CLI will use a built-in version of adb.
To avoid possible issues with the native Android emulator, Genymotion or connected
Android devices, verify that you have installed the latest Android SDK and
its dependencies as described in     http://developer.android.com/sdk/index.html#Requirements

TIP: To avoid setting up the necessary environment variables, you can use the Homebrew package manager to install the Android SDK and its dependencies.

Verifying CocoaPods. This may take more than a minute, please be patient.
  ◜ Installing iOS runtime.⸨░░░░░░░░░░░░░░░░░░⸩ ⠧ normalizeTree: sill install lo      
◠ Installing iOS runtime.⸨░░░░░░░░░░░░░░░░░░⸩ ⠙ normalizeTree: sill install lo  
◝ Installing iOS runtime.⸨░░░░░░░░░░░░░░░░░░⸩ ⠙ normalizeTree: sill install lo  
◞ Installing iOS runtime.⸨░░░░░░░░░░░░░░░░░░⸩ ⠙ normalizeTree: sill install lo  
◡ Installing iOS runtime.⸨░░░░░░░░░░░░░░░░░░⸩ ⠙ normalizeTree: sill install lo  
◟ Installing iOS runtime.⸨   ░░░░░░░░░░░░░░░⸩ ⠧ cloneCurrentTree: sill cloneCu  
◜ Installing iOS runtime.⸨    ░░░░░░░░░░░░░░⸩ ⠙ loadRequestedDeps: sill instal  
◠ Installing iOS runtime.⸨    ░░░░░░░░░░░░░░⸩ ⠙ loadRequestedDeps: sill instal      
◝ Installing iOS runtime.⸨    ░░░░░░░░░░░░░░⸩ ⠙ loadRequestedDeps: sill instal  
◞ Installing iOS runtime.⸨    ░░░░░░░░░░░░░░⸩ ⠙ loadRequestedDeps: sill instal  
◡ Installing iOS runtime.⸨    ░░░░░░░░░░░░░░⸩ ⠙ loadRequestedDeps: sill instal  
◟ Installing iOS runtime.⸨    ░░░░░░░░░░░░░░⸩ ⠙ loadRequestedDeps: sill instal  
◜ Installing iOS runtime.⸨    ░░░░░░░░░░░░░░⸩ ⠙ loadRequestedDeps: sill instal  
◠ Installing iOS runtime.⸨    ░░░░░░░░░░░░░░⸩ ⠙ loadRequestedDeps: sill instal  
◝ Installing iOS runtime.⸨    ░░░░░░░░░░░░░░⸩ ⠙ loadRequestedDeps: sill instal  
◞ Installing iOS runtime.⸨    ░░░░░░░░░░░░░░⸩ ⠙ loadRequestedDeps: sill instal  
◡ Installing iOS runtime.⸨    ░░░░░░░░░░░░░░⸩ ⠙ loadRequestedDeps: sill instal  
◟ Installing iOS runtime.⸨             ░░░░░⸩ ⠧ extract:tns-ios: sill doParall  
◜ Installing iOS runtime.⸨             ░░░░░⸩ ⠇ extract:tns-ios: sill doParall  
◠ Installing iOS runtime.⸨             ░░░░░⸩ ⠇ extract:tns-ios: sill doParall  
◝ Installing iOS runtime.⸨             ░░░░░⸩ ⠇ extract:tns-ios: sill doParall  
◞ Installing iOS runtime.⸨             ░░░░░⸩ ⠇ extract:tns-ios: sill doParall  
◡ Installing iOS runtime.⸨             ░░░░░⸩ ⠦ extract:tns-ios: sill doParall  
◟ Installing iOS runtime.⸨             ░░░░░⸩ ⠏ extract:tns-ios: sill doParall  
◜ Installing iOS runtime.⸨             ░░░░░⸩ ⠇ extract:tns-ios: sill doParall  
◠ Installing iOS runtime.⸨             ░░░░░⸩ ⠇ extract:tns-ios: sill doParall  
◝ Installing iOS runtime.⸨             ░░░░░⸩ ⠇ extract:tns-ios: sill doParall  
◞ Installing iOS runtime.⸨             ░░░░░⸩ ⠇ extract:tns-ios: sill doParall  
◡ Installing iOS runtime.⸨             ░░░░░⸩ ⠇ extract:tns-ios: sill doParall  
◟ Installing iOS runtime.⸨             ░░░░░⸩ ⠇ extract:tns-ios: sill doParall  
◜ Installing iOS runtime.⸨             ░░░░░⸩ ⠇ extract:tns-ios: sill doParall  
◠ Installing iOS runtime.⸨             ░░░░░⸩ ⠇ extract:tns-ios: sill doParall  
◝ Installing iOS runtime.⸨             ░░░░░⸩ ⠸ extract:tns-ios: sill doParallnativescript-check-cocoapods@0.0.1 /private/var/folders/k5/jmd4lpjs4d9g2h9g_qw5qypm0000gn/T/nativescript-check-cocoapods117414-14624-9zer4y.acgt8uayvi
└── tns-ios@3.0.0 

npm WARN nativescript-check-cocoapods@0.0.1 No description
npm WARN nativescript-check-cocoapods@0.0.1 No repository field.
npm WARN nativescript-check-cocoapods@0.0.1 No license field.

  ◠ Verifying CocoaPods. This may take some time, please be patient..
Path must be a string. Received undefined
Failed to display command help { Error
at Object.<anonymous> (/Users/theobalestra/.npm-    packages/lib/node_modules/nativescript/lib/common/errors.js:15:23)
    at Module._compile (module.js:570:32)
    at Object.Module._extensions..js (module.js:579:10)
    at Module.load (module.js:487:32)
    at tryModuleLoad (module.js:446:12)
    at Function.Module._load (module.js:438:3)
    at Module.require (module.js:497:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/Users/theobalestra/.npm-    packages/lib/node_modules/nativescript/lib/nativescript-cli.js:14:18)
    at Module._compile (module.js:570:32)
  name: 'Exception',
  message: 'Unknown command \'post-install-cli\'. Try \'$ tns help\'     for a full list of supported commands.',
  errorCode: 127,
  suppressCommandHelp: true }
/Users/theobalestra/.npm-packages/lib
└── nativescript@3.0.1 

最近的更新已弃用部分nativescript docs macos设置步骤,特别是以下内容:

android update sdk --filter tools,platform-tools,android-25,build-tools-25.0.2,extra-android-m2repository,extra-google-m2repository,extra-android-support --all --no-ui

您可以使用sdkmanager --list来确定缺少哪些包。 至少你应该:

build-tools;25.0.2
extras;android;m2repository
extras;google;m2repository
platform-tools
platforms;android-25
tools

如果缺少任何内容,请使用sdkmanager安装它们:

sdkmanager "extras;android;m2repository"
sdkmanager "extras;google;m2repository"
etc

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM