2017-08-17 134 views
0

我一直在安裝豆莢,豆莢已正確安裝。但是,在項目導航器中,.xcconfig文件呈紅色,我無法在項目 - >信息 - >配置中設置相同,因爲它們未列出,只列出任何項目。調試時,我能找到的.xcconfig文件由Xcode的以下路徑豆莢安裝不正確

/Volumes/Macintosh HD/Users/xxxxxxxxxx/Documents/xxxxxxxx/app/Pods/Pods/Target Support Files/Pods-broadcastuploadSetupUI/Pods-broadcastuploadSetupUI.release.xcconfig 

/莢得到訪問的有兩次,因爲其中我收到以下錯誤:

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. 

我正在使用Xcode 9測試版。任何人都可以提供幫助嗎?

P.S,我嘗試了sudo gem install,pod更新,解體,安裝以及互聯網上提供的一切解決方案。我會很高興,如果有人可以幫助

這是我podfile:

#platform :ios, ‘11.0’ 
source 'https://URL_TO_ACCESS_PODSPEC_FOR_POD' 
source 'https://github.com/CocoaPods/Specs.git' 


target 'app' do 
pod 'objective-zip', '~> 1.0' 
pod 'AssistScreenShareKit' 
use_frameworks! 
end 

target ‘broadcastupload’ do 
    pod 'AssistScreenShareKit' 
use_frameworks! 
end 

target ‘broadcastuploadSetupUI' do 
pod 'AssistScreenShareKit' 
use_frameworks! 
end 

錯誤:

The file 「Pods-app.release.xcconfig」 couldn’t be opened because there is no such file. (/Volumes/Macintosh HD/Users/xxxxxxxx/Documents/xxxxx/app/Pods/Pods/Target Support Files/Pods-app/Pods-app.release.xcconfig) 
+0

刪除您的工作區,pod鎖定,pod文件,pod文件夾,派生數據,然後再次初始化pod文件並重新安裝 - 清理,編譯並運行。 – Rivendell

+0

讓我試試這個 –

+0

我試過了,但不幸的是,沒有成功! :/ –

回答

0

步驟安裝莢

  1. 打開一個終端窗口, $ cd到您的項目目錄中。
  2. 要創建Podfile,您需要運行$ pod init.
  3. 打開您的Podfile。第一行應指定所支持的平臺和版本號。
platform :ios, '9.0' 

use_frameworks! target 'yourProjectName' do 
    pod 'Alamofire' end 
  • 然後安裝莢
  • pod install

    +0

    沒有工作Saurabh! –

    +0

    您是否檢查過您的代碼是否需要在編輯下轉換爲當前Swift語法。 –

    0

    首先刪除所有吊艙和Podfile.lock

    1. 打開終端進入這個

      platform :ios, '8.0' use_frameworks! target 'MyApp' do //add your all pods end

    2. pod install

    3. 密切Xcode和開放MyApp.xcworkspace文件

    檢查文件夾路徑

  • 編輯您的podfile F或更多:Command-line Reference

    這會幫助你。

  • +0

    謝謝,但它沒有工作Yuyutsu。 –

    +0

    你可以刪除'source'https:// URL_TO_ACCESS_PODSPEC_FOR_POD'' 'source'https:// github.com/CocoaPods/Specs.git''這一行 – Yuyutsu

    +0

    這不是一個pod,它的podspec文件在Cocopods 。它是一個本地提到的pod,所以它必須在那裏才能識別podspec文件 –