【发布时间】:2017-10-07 20:46:05
【问题描述】:
我正在使用 Apache Cordova 6.5,添加 iOS 平台并尝试在由 cordova iOS 项目创建的工作区中使用 cocoapods。
当我运行命令时
吊舱安装
Xcode 项目无法编译,出现以下错误
diff: /../Podfile.lock: No such file or directory
diff: /Manifest.lock: No such file or directory
error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.
以下是解决此问题的步骤:
- 创建一个新的 Cordova 6.5 项目
cordova 创建 app1
- 进入项目文件夹,添加iOS平台
cd app1/
cordova平台添加ios
- 转到 iOS 项目文件夹并运行 pods
cd 平台/ios
pod 初始化
吊舱安装
我尝试了基本的 podfile 和一个我添加了我的工作区名称的文件
# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'
workspace 'HelloCordova'
xcodeproj 'HelloCordova.xcodeproj'
target 'HelloCordova' do
# Uncomment the next line if you're using Swift or would like to use dynamic frameworks
# use_frameworks!
# Pods for HelloCordova
end
知道如何解决这个问题吗?
PS:我使用的是cordova 6.5.0、cordova-ios 4.3.1、Xcode 8.2
【问题讨论】:
标签: ios xcode cordova cocoapods